The crwPostIS draws a set of states from the posterior distribution of a fitted CTCRW model. The draw is either conditioned on the fitted parameter values or "full" posterior draw with approximated parameter posterior
crwPostIS(object.sim, fullPost = TRUE, df = Inf, scale = 1, thetaSamp = NULL)
List with the following elements:
A matrix a simulated latitude state values
Matrix of simulated longitude state values
Indicates prediction types with a "p" or observation times with an "o"
Initial state covariance for latitude
log likelihood of simulated parameter
Simulated parameter value
non normalized log importance sampling weight
A crwSimulator object from crwSimulator
.
logical. Draw parameter values as well to simulate full posterior
degrees of freedom for multivariate t distribution approximation to parameter posterior
Extra scaling factor for t distribution approximation
If multiple parameter samples are available in object.sim,
setting thetaSamp=n
will use the nth sample. Defaults to the last.
Devin S. Johnson
The crwPostIS draws a posterior sample of the track state matrices. If fullPost was set to TRUE when the object.sim was build in crwSimulator then a pseudo-posterior draw will be made by first sampling a parameter value from a multivariate t distribution which approximates the marginal posterior distribution of the parameters. The covariance matrix from the fitted model object is used to scale the MVt approximation. In addition, the factor "scale" can be used to further adjust the approximation. Further, the parameter simulations are centered on the fitted values.
To correct for the MVt approximation, the importance sampling weight is also supplied. When calculating averages of track functions for Bayes estimates one should use the importance sampling weights to calculate a weighted average (normalizing first, so the weights sum to 1).
See demo(northernFurSealDemo)
for example.