getprior | R Documentation |
A sample of specified size is obtained from the prior distribution.
getprior(prior.alpha, n)
prior.alpha |
A list of length 3 containing the distributional information for the prior. The first element is a number from 1-4 specifying the type of distribution. Options are
The second and third elements of the list are the parameters a and b, respectively. |
n |
The number of samples. |
A vector of size n
is returned from the specified prior distribution.
Michael Sweeting mjs212@medschl.cam.ac.uk (University of Cambridge, UK), drawing on code originally developed by J. Jack Lee and Nan Chen, Department of Biostatistics, the University of Texas M. D. Anderson Cancer Center
Sweeting M., Mander A., Sabin T. bcrm: Bayesian Continual Reassessment Method Designs for Phase I Dose-Finding Trials. Journal of Statistical Software (2013) 54: 1–26. doi: 10.18637/jss.v054.i13
bcrm
, find.x
prior.alpha <- list(1, 1, 1) samples.alpha <- getprior(prior.alpha, 2000) hist(samples.alpha)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.