Description Usage Arguments Details Value Author(s) References Examples
Plot effective current sample size (ECSS) on a grid for a list of priors.
1 |
priorlist |
A named list of priors. Elements can be |
grid |
The grid of true data means (see details in |
n.target |
The sample size of interest at which the ECSS is evaluated |
min.ecss |
minimal ECSS of interest (usually negative) |
progress |
name of the progress bar to use, see |
... |
Further arguments to be passed to |
Plot effective current sample size (ECSS) on a grid for a list of priors. This is useful to visualize the impact of a prior for a range of true values at planning stage, i.e. in prospective use before seeing the data. See also vignette and Wiesenfarth and Calderazzo (2019).
plot |
A "ggplot" object |
data |
A data frame with computed values |
Manuel Wiesenfarth
Wiesenfarth, M., Calderazzo, S. (2019). Quantification of Prior Impact in Terms of Effective Current Sample Size. Submitted.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | # Normal Outcome
# standard deviation
sigma=1
# baseline
rob=c(0,10)
vague <-mixnorm(vague=c(1, rob), sigma=sigma)
# prior with nominal prior ESS=50
inf=c(0,1/sqrt(50))
info <-mixnorm(informative=c(1, inf), sigma=sigma)
# robust mixture
mix50 <-mixnorm(informative=c(.5, inf),vague=c(.5, rob), sigma=sigma)
plotECSS(priorlist=list(mix=mix50,info=info), grid=((-8:8)/10), n.target=200,
min.ecss=-200,sigma=sigma,prior.base=vague)
# See also vignette for more extensive example.
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.