mhStep: Computes a Metropolis Hastings Step

Description Usage Arguments Value

View source: R/mhStep.R

Description

Internal. Performs Metropolis Hastings steps for internal MCMC procedure. lpost_old/lpost_new are log-posteriors at theta_old/theta_new

Usage

1
mhStep(theta_old, theta_new, lpost_old, lpost_new, lq_new, lq_old)

Arguments

theta_old

old proposal parameter value

theta_new

new proposal parameter value

lpost_old

old log posterior

lpost_new

new log posterior

lq_new

log q(theta_new|theta_old) the proposal log-densities

lq_old

log q(theta_old|theta_new) the proposal log-densities

Value

A list of the new theta accepted value, or the old value if rejected and an acceptance indicator.


PatrickPfeifferDSc/bite documentation built on Aug. 22, 2019, 9:57 a.m.