Rev Language Reference


mvIidPrior - Move to propose from prior

This move proposes new values drawn from the prior.

Usage

mvIidPrior(Real x, RealPos weight, Probability tuneTarget)

Arguments

x : Real (<stochastic> pass by reference)
The variable on which this move operates.
weight : RealPos (pass by value)
The weight determines the relative frequency with which this move will be attempted. For details, see the description of the 'moveschedule' parameter on the documentation page for 'mcmc()'.
Default : 1
tuneTarget : Probability (pass by value)
The acceptance probability targeted by auto-tuning.
Default : 0.44

Details

Using this move, one actually gets an independence sampler as the proposal doesn't depend on the current state. The move calls redraw based on the distribution attached to the random variable.

Example

x ~ dnUnif(0,10000)
moves[1] = mvIidPrior(x, weight=1.0)
monitors[1] = screenmonitor(printgen=1000, x)
mymodel = model(x)
mymcmc = mcmc(mymodel, monitors, moves)
mymcmc.run(generations=200000)