cov.match.sample: Sample with covariance-matching slice sampling

View source: R/cov-match.R

cov.match.sampleR Documentation

Sample with covariance-matching slice sampling

Description

Generate a sample from a probability distribution with the covariance-matching slice sampling method.

Usage

cov.match.sample(target.dist, x0, sample.size, tuning=1,
                 theta=1, limit=length(x0)*100)

Arguments

target.dist

Target distribution; see make.dist.

x0

Initial coordinates.

sample.size

Sample size to draw.

tuning

A tuning parameter; corresponds to \sigma_c in sec. 4 of Thompson and Neal (2010).

theta

A factor to scale the crumb standard deviation in every direction after a proposal is rejected. So, after k proposals, crumbs have standard deviation theta^k*tuning in directions orthogonal to all the proposal gradients.

limit

A limit on the number of log-density evaluations per observation before sampling is aborted.

Details

This function implements the covariance-matching method of slice sampling, as described by Thompson and Neal (2010). It can be passed to compare.samplers in the samplers list argument.

Value

A list with elements X, evals, grads, and adapt.rate. adapt.rate indicates the fraction of crumb draws that resulted in adaptation. This sampler follows the calling convention of compare.samplers.

References

Thompson, M. B. and Neal, R. M. (2010). Covariance-adaptive slice sampling. Technical Report TR-1002, Dept. of Statistics, University of Toronto.

See Also

compare.samplers, shrinking.rank.sample


SamplerCompare documentation built on April 24, 2023, 9:09 a.m.