mhmix                  package:mcsm                  R Documentation

_I_m_p_l_e_m_e_n_t _t_w_o _M_e_t_r_o_p_o_l_i_s-_H_a_s_t_i_n_g_s _a_l_g_o_r_i_t_h_m_s _o_n _a _m_i_x_t_u_r_e _p_o_s_t_e_r_i_o_r

_D_e_s_c_r_i_p_t_i_o_n:

     This function runs a Metropolis-Hastings algorithm on a posterior
     distribution associated with a mixture model and 500 datapoints.
     Depending on the value of the boolean indicator 'lange', the
     function  uses a regular Gaussian random-walk proposal or a
     Langevin alternative.

_U_s_a_g_e:

     mhmix(Niter = 10^4, lange = FALSE, scale = 1)

_A_r_g_u_m_e_n_t_s:

   Niter: Number of MCMC iterations

   lange: Boolean variable indicating the use of the Langevin
          alternative

   scale: Scale factor of the Gaussian perturbation

_V_a_l_u_e:

     The function returns a plot of the log-posterior surface, along
     with the MCMC sample represented both by points and lines linking
     one value to the next.

_A_u_t_h_o_r(_s):

     Christian P. Robert and George Casella

_R_e_f_e_r_e_n_c_e_s:

     Chapter 6 of *EnteR Monte Carlo Statistical Methods*

_E_x_a_m_p_l_e_s:

     ## Not run: mhmix(Nit=10^3,scale=2)
     #you can also try mhmix(lange=TRUE,scale=.1)

