Description Usage Arguments References Examples
Returns a p-value for testing the hypothesis that mu
is the pct
^th
percentile of the population effect distribution based on the nonparametric sign test
method of Wang et al. (2010). This function is also called by prop_stronger
when using the sign test method.
1 | pct_pval(yi, sei, mu, pct, R = 2000)
|
yi |
Vector of study-level point estimates |
sei |
Vector of study-level standard errors |
mu |
The effect size to test as the |
pct |
The percentile of interest (e.g., 0.50 for the median) |
R |
Number of simulation iterates to use when estimating null distribution of the test statistic. |
Wang R, Tian L, Cai T, & Wei LJ (2010). Nonparametric inference procedure for percentiles of the random effects distribution in meta-analysis. Annals of Applied Statistics.
1 2 3 4 5 6 7 8 9 10 11 | # calculate effect sizes for example dataset
d = metafor::escalc(measure="RR", ai=tpos, bi=tneg,
ci=cpos, di=cneg, data=metadat::dat.bcg)
# test H0: the median is -0.3
# using only R = 100 for speed, but should be much larger (e.g., 2000) in practice
pct_pval( yi = d$yi,
sei = sqrt(d$vi),
mu = -0.3,
pct = 0.5,
R = 100 )
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.