Function to compute the fail-safe N (also called a file drawer analysis).
fsn(yi, vi, sei, data, type="Rosenthal", alpha=.05,
target, weighted=FALSE, subset, digits, ...)
An object of class "fsn"
. The object is a list containing the following components:
the method used.
the calculated fail-safe N.
the specified alpha level.
the p-value of the observed results. NA
for the Orwin method.
the average outcome of the observed results. NA
for the Rosenthal method.
the target value. NA
for the Rosenthal and Rosenberg methods.
The results are formatted and printed with the print
function.
vector with the observed effect sizes or outcomes.
vector with the corresponding sampling variances.
vector with the corresponding standard errors (note: only one of the two, vi
or sei
, needs to be specified).
optional data frame containing the variables given to the arguments above.
character string to specify the method to use for the calculation of the fail-safe N. Possible options are "Rosenthal"
(the default), "Orwin"
, or "Rosenberg"
. See ‘Details’.
target alpha level to use for the Rosenthal and Rosenberg methods (the default is .05).
target average effect size or outcome to use for the Orwin method. If undefined, then the target average effect size or outcome will be equal to the observed average effect size or outcome divided by 2.
logical to specify whether Orwin's method should be based on unweighted (the default) or weighted averages (the default is FALSE
).
optional (logical or numeric) vector to specify the subset of studies that should be used for the calculations.
optional integer to specify the number of decimal places to which the printed results should be rounded.
other arguments.
Wolfgang Viechtbauer wvb@metafor-project.org https://www.metafor-project.org
The function can be used in combination with any of the usual effect sizes / outcome measures used in meta-analyses (e.g., log risk ratios, log odds ratios, risk differences, mean differences, standardized mean differences, raw correlation coefficients, correlation coefficients transformed with Fisher's r-to-z transformation), or, more generally, any set of estimates (with corresponding sampling variances) one would like to analyze. Simply specify the observed outcomes via the yi
argument and the corresponding sampling variances via the vi
argument (instead of specifying vi
, one can specify the standard errors via the sei
argument). The escalc
function can be used to compute a wide variety of effect sizes / outcome measures (and the corresponding sampling variances) based on summary statistics.
The Rosenthal method (sometimes called a ‘file drawer analysis’) calculates the number of studies averaging null results that would have to be added to the given set of observed outcomes to reduce the combined significance level (p-value) to a particular alpha level (e.g., .05). The calculation is based on Stouffer's method to combine p-values and is described in Rosenthal (1979).
The Orwin method calculates the number of studies averaging null results that would have to be added to the given set of observed outcomes to reduce the (unweighted or weighted) average outcome to a target value (as specified via the target
argument). The method is described in Orwin (1983). If weighted=FALSE
(the default), the method does not require (or makes use) of vi
(or sei
), so these arguments are then not relevant for this method. If the target
argument is not specified, then the target average outcome will be equal to the observed average outcome divided by 2 (which is quite arbitrary). One should really set target
to a value that reflects an outcome one would consider practically irrelevant. Note that if target
has the opposite sign as the actually observed average outcome, then its sign is automatically flipped.
The Rosenberg method calculates the number of studies averaging null results that would have to be added to the given set of observed outcomes to reduce the significance level (i.e., p-value) of the weighted average outcome (based on an equal-effects model) to a particular alpha level (e.g., .05). The method is described in Rosenberg (2005).
If the combined/observed significance level is above the specified alpha level (for type = "Rosenthal"
or type = "Rosenberg"
) or if the observed average outcome is below the target average outcome (for type = "Orwin"
), then the fail-sage N value will be 0.
Rosenthal, R. (1979). The "file drawer problem" and tolerance for null results. Psychological Bulletin, 86(3), 638--641. https://doi.org/10.1037/0033-2909.86.3.638
Orwin, R. G. (1983). A fail-safe N for effect size in meta-analysis. Journal of Educational Statistics, 8(2), 157--159. https://doi.org/10.3102/10769986008002157
Rosenberg, M. S. (2005). The file-drawer problem revisited: A general weighted method for calculating fail-safe numbers in meta-analysis. Evolution, 59(2), 464--468. https://doi.org/10.1111/j.0014-3820.2005.tb01004.x
Viechtbauer, W. (2010). Conducting meta-analyses in R with the metafor package. Journal of Statistical Software, 36(3), 1--48. https://doi.org/10.18637/jss.v036.i03
ranktest
for the rank correlation test, regtest
for the regression test, trimfill
for the trim and fill method, tes
for the test of excess significance, and selmodel
for selection models.
### calculate log risk ratios and corresponding sampling variances
dat <- escalc(measure="RR", ai=tpos, bi=tneg, ci=cpos, di=cneg, data=dat.bcg)
### fit equal-effects model
rma(yi, vi, data=dat, method="EE")
### fail-safe N computations
fsn(yi, vi, data=dat)
fsn(yi, data=dat, type="Orwin", target=log(0.95)) # target corresponds to a 5% risk reduction
fsn(yi, vi, data=dat, type="Orwin", weighted=TRUE, target=log(0.95))
fsn(yi, vi, data=dat, type="Rosenberg")
Run the code above in your browser using DataLab