univ_proposal: MCMC proposal function

View source: R/proposal_theta.R

univ_proposalR Documentation

MCMC proposal function

Description

Proposal function for MCMC random walk, taking random steps of a given size.

Usage

univ_proposal(
  values,
  lower_bounds,
  upper_bounds,
  steps,
  index,
  gaussian_proposal = FALSE
)

Arguments

values

a vector of the parameters to be explored

lower_bounds

a vector of the low allowable bounds for the proposal

upper_bounds

a vector of the upper allowable bounds for the proposal

steps

a vector of step sizes for the proposal

index

numeric value for the index of the parameter to be moved from the param table and vector

gaussian_proposal

if TRUE, then samples moves from a Gaussian distribution centered around the current value

Value

the parameter vector after step

See Also

Other proposals: inf_hist_swap_phi(), inf_hist_swap(), infection_history_symmetric(), mvr_proposal()


adamkucharski/serosolver documentation built on March 18, 2024, 6:07 p.m.