Learn R Programming

geoCount (version 1.150120)

cutChain: Modify Markov Chains with Burn-in and Thining

Description

This function takes the results from runMCMC and modifies the chains of posterior samples for burn-in and thinning.

Usage

cutChain(res, chain.ind=2:4, burnin, thinning)

Arguments

res
a list with elements containing the posterior samples of latent variables and parameters; usually the output from runMCMC
chain.ind
the index of elements in "res" that will be modified
burnin
the number for burn-in
thinning
the number for thining

Value

A list with elements containing the modified posterior samples.

See Also

runMCMC, mixChain.

Examples

Run this code
## Not run: 
# res <- runMCMC(Y, L=0, loc=loc, MCMCinput = input )
# res.m <- cutChain(res, chain.ind=1:4, burnin=100, thining=10)
# ## End(Not run)

Run the code above in your browser using DataLab