Description Usage Arguments Value
Sampling via the accept-reject algorithm. The proposal distribution is taken as normal, with the option to specify the mean and variance.
1 2 |
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. |
Vector of realizations from the mixture density.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.