drop_realization: Drop MCMC realizations

Description Usage Arguments Author(s) See Also Examples

View source: R/get_post.R

Description

The function drops realizations from a DAMCMC or BDMCMC fit and returns the resulting fit object.

For examples see

http://faculty.missouri.edu/~micheasa/sppmix/sppmix_all_examples.html#drop_realization

Usage

1
drop_realization(fit, drop = 0.1 * fit$L)

Arguments

fit

Object of class damcmc_res or bdmcmc_res.

drop

If one integer is provided, the function will drop the first 1:drop realizations. If an integer vector is provided, it will drop these iterations. If a logical vector is provided (with the same length as the chain length of fit), it will be used for subsetting directly.

Author(s)

Sakis Micheas, Yuchen Wang

See Also

est_mix_bdmcmc

Examples

1
2
3
4
fit <- est_mix_bdmcmc(spatstat::redwood, m = 5)
fit
drop_realization(fit, 500)
drop_realization(fit, fit$numcomp != 5)

sppmix documentation built on Jan. 13, 2021, 10:04 p.m.