ssdPs: Sample size determination for replication success based on...

View source: R/ssdPs.R

ssdPsR Documentation

Sample size determination for replication success based on the sceptical p-value

Description

This function computes the standard error required to achieve replication success with a certain probability and based on the sceptical p-value.

Usage

ssdPs(level, dprior, power)

Arguments

level

Threshold for the (one-sided) sceptical p-value below which replication success is achieved

dprior

Design prior object

power

Desired probability of replication success

Details

The sceptical p-value is assumed to be uncalibrated as in Held (2020). The package ReplicationSuccess allows for sample size and power calculations with the recalibrated sceptical p-value (https://CRAN.R-project.org/package=ReplicationSuccess).

Value

Returns an object of class "ssdRS". See ssd for details.

Author(s)

Samuel Pawel

References

Pawel, S., Consonni, G., and Held, L. (2022). Bayesian approaches to designing replication studies. arXiv preprint. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.48550/arXiv.2211.02552")}

Held, L. (2020). A new standard for the analysis and design of replication studies (with discussion). Journal of the Royal Statistical Society: Series A (Statistics in Society), 183(2), 431-448. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1111/rssa.12493")}

Examples

## specify design prior
to1 <- 0.2
so1 <- 0.05
dprior <- designPrior(to = to1, so = so1, tau = 0.03)
ssdPs(level = 0.05, dprior = dprior, power = 0.9)


BayesRepDesign documentation built on May 4, 2023, 1:07 a.m.