Learn R Programming

networkTomography (version 0.3)

move_step: Move step of sample-resample-move algorithm for multilevel state-space model

Description

Function to execute single MCMC-based move step for bayesianDynamicFilter. This can use two types of stopping rules: number of iterations or number of accepted moves for the X particles. The former is used by default, but the latter adapts better to low acceptance rates (sometimes with substantial computational cost). Most updates in this algorithm are Metropolis-Hastings with customized proposals.

Usage

move_step(y, X, tme, lambda, phi, lambdatm1, phitm1, prior, A, A1_inv, A2, rho, tau, m = ncol(X), l = nrow(A1_inv), k = length(lambda), ndraws = 10, minAccepts = 0, verbose = FALSE)

Arguments

y
numeric vector (length l) of observed link loads
X
matrix (m x k) of particles for OD flows, one particle per row, in pivoted order
tme
integer time index currently used in estimation
lambda
matrix (m x k) of particles for OD intensities, one particle per row, in pivoted order
phi
numeric vector (length m) of particles for phi
lambdatm1
lambda matrix (m x k) of particles for OD intensities from previous time, one particle per row, in pivoted order
phitm1
numeric vector (length m) of particles for phi from previous time
prior
list containing priors for hyperparameters; see bayesianDynamicFilter for details
A
routing matrix (l x k) for network
A1_inv
inverse of full-rank portion of routing matrix (l x l)
A2
remainder of routing matrix (l x k-l)
rho
numeric fixed autoregressive parameter for dynamics on lambda; see reference for details
tau
numeric fixed power parameter for variance structure on truncated normal noise; see reference for details
m
integer number of particles
l
integer number of observed link loads
k
integer number of OD flows to infer
ndraws
integer number of draws to perform (can be overriden by minAccepts)
minAccepts
integer minimum number of acceptances before results are returned; activates alternative stopping rule if >= 1
verbose
logical activates verbose diagnostic output

Value

list containing updated values of X, lambda, and phi

References

A.W. Blocker and E.M. Airoldi. Deconvolution of mixing time series on a graph. Proceedings of the Twenty-Seventh Conference Annual Conference on Uncertainty in Artificial Intelligence (UAI-11) 51-60, 2011.

See Also

Other bayesianDynamicModel: bayesianDynamicFilter; buildPrior