pmcmc {pomp} | R Documentation |
The particle Markov chain Metropolis-Hastings algorithm
Description
The Particle MCMC algorithm for estimating the parameters of a
partially-observed Markov process. Running pmcmc
causes a particle
random-walk Metropolis-Hastings Markov chain algorithm to run for the
specified number of proposals.
Usage
## S4 method for signature 'data.frame'
pmcmc(
data,
Nmcmc = 1,
proposal,
Np,
params,
rinit,
rprocess,
dmeasure,
dprior,
...,
verbose = getOption("verbose", FALSE)
)
## S4 method for signature 'pomp'
pmcmc(
data,
Nmcmc = 1,
proposal,
Np,
...,
verbose = getOption("verbose", FALSE)
)
## S4 method for signature 'pfilterd_pomp'
pmcmc(
data,
Nmcmc = 1,
proposal,
Np,
...,
verbose = getOption("verbose", FALSE)
)
## S4 method for signature 'pmcmcd_pomp'
pmcmc(data, Nmcmc, proposal, ..., verbose = getOption("verbose", FALSE))
Arguments
data |
either a data frame holding the time series data,
or an object of class ‘pomp’,
i.e., the output of another pomp calculation.
Internally, |
Nmcmc |
The number of PMCMC iterations to perform. |
proposal |
optional function that draws from the proposal distribution. Currently, the proposal distribution must be symmetric for proper inference: it is the user's responsibility to ensure that it is. Several functions that construct appropriate proposal function are provided: see MCMC proposals for more information. |
Np |
the number of particles to use.
This may be specified as a single positive integer, in which case the same number of particles will be used at each timestep.
Alternatively, if one wishes the number of particles to vary across timesteps, one may specify length(time(object,t0=TRUE)) or as a function taking a positive integer argument.
In the latter case, |
params |
optional; named numeric vector of parameters.
This will be coerced internally to storage mode |
rinit |
simulator of the initial-state distribution.
This can be furnished either as a C snippet, an R function, or the name of a pre-compiled native routine available in a dynamically loaded library.
Setting |
rprocess |
simulator of the latent state process, specified using one of the rprocess plugins.
Setting |
dmeasure |
evaluator of the measurement model density, specified either as a C snippet, an R function, or the name of a pre-compiled native routine available in a dynamically loaded library.
Setting |
dprior |
optional; prior distribution density evaluator, specified either as a C snippet, an R function, or the name of a pre-compiled native routine available in a dynamically loaded library.
For more information, see prior specification.
Setting |
... |
additional arguments are passed to |
verbose |
logical; if |
Value
An object of class ‘pmcmcd_pomp’.
Methods
The following can be applied to the output of a pmcmc
operation:
pmcmc
repeats the calculation, beginning with the last state
continue
continues the
pmcmc
calculationplot
produces a series of diagnostic plots
filter_traj
extracts a random sample from the smoothing distribution
traces
produces an
mcmc
object, to which the various coda convergence diagnostics can be applied
Re-running PMCMC Iterations
To re-run a sequence of PMCMC
iterations, one can use the pmcmc
method on a ‘pmcmc’ object.
By default, the same parameters used for the original PMCMC run are re-used
(except for verbose
, the default of which is shown above). If one
does specify additional arguments, these will override the defaults.
Note for Windows users
Some Windows users report problems when using C snippets in parallel computations.
These appear to arise when the temporary files created during the C snippet compilation process are not handled properly by the operating system.
To circumvent this problem, use the cdir
and cfile
options to cause the C snippets to be written to a file of your choice, thus avoiding the use of temporary files altogether.
Author(s)
Edward L. Ionides, Aaron A. King, Sebastian Funk
References
C. Andrieu, A. Doucet, and R. Holenstein. Particle Markov chain Monte Carlo methods. Journal of the Royal Statistical Society, Series B 72, 269–342, 2010. doi:10.1111/j.1467-9868.2009.00736.x.
See Also
More on pomp estimation algorithms:
abc()
,
bsmc2()
,
estimation_algorithms
,
mif2()
,
nlf
,
pomp-package
,
probe_match
,
spect_match
More on sequential Monte Carlo methods:
bsmc2()
,
cond_logLik()
,
eff_sample_size()
,
filter_mean()
,
filter_traj()
,
kalman
,
mif2()
,
pfilter()
,
pred_mean()
,
pred_var()
,
saved_states()
,
wpfilter()
More on full-information (i.e., likelihood-based) methods:
bsmc2()
,
mif2()
,
pfilter()
,
wpfilter()
More on Markov chain Monte Carlo methods:
abc()
,
proposals
More on Bayesian methods:
abc()
,
bsmc2()
,
dprior()
,
prior_spec
,
rprior()