Sample.EF: Sample Fitted Exponential Family

Description Usage Arguments Value

View source: R/Fit.R

Description

Sampling via the accept-reject algorithm. The proposal distribution is taken as normal, with the option to specify the mean and variance.

Usage

1
2
Sample.EF(z, f, m = NULL, v = NULL, n = 1000, parallel = F,
  maxit = 25)

Arguments

z

Observations.

f

Density to sample.

m

Proposal mean.

v

Proposal variance.

n

Target number of sample to obtain.

parallel

Run in parallel? Must register parallel backend first.

maxit

Maximum number of accept-reject iterations.

Value

Vector of realizations from the mixture density.


zrmacc/LFDR documentation built on May 3, 2019, 9:01 p.m.