shape_adapter {rmcmc} | R Documentation |
Create object to adapt proposal shape.
Description
Create object to adapt proposal shape.
Usage
shape_adapter(type = "covariance", kappa = 1)
Arguments
type |
Type of shape adapter to use. One of:
|
kappa |
Decay rate exponent in |
Value
List of functions with entries
-
initialize
, a function for initializing adapter state and proposal parameters at beginning of chain, -
update
a function for updating adapter state and proposal parameters on each chain iteration, -
finalize
a function for performing any final updates to adapter state and proposal parameters on completion of chain sampling (may beNULL
if unused). -
state
a zero-argument function for accessing current values of adapter state variables.
See Also
variance_shape_adapter()
, covariance_shape_adapter()
Examples
proposal <- barker_proposal()
adapter <- shape_adapter()
adapter$initialize(proposal, chain_state(c(0, 0)))