Learn R Programming

PublicationBiasBenchmark (version 0.1.3)

method.pcurve: pcurve (P-Curve) Method

Description

Implements the p-Curve method which analyzes the distribution of p-values from significant studies to assess whether the significant findings reflect true effects or QRP/publication bias. The method also provides tests for the evidential value, lack of evidential value, and p-hacking. See simonsohn2014pcurve;textualPublicationBiasBenchmark for details.

The current implementation does not provide a test against the null hypothsis of no effect and does not produce confidence intervals of the estimate.

Usage

# S3 method for pcurve
method(method_name, data, settings)

Value

Data frame with P-Curve results

Arguments

method_name

Method name (automatically passed)

data

Data frame with yi (effect sizes), sei (standard errors), and ni (sample sizes wherever available, otherwise set to Inf)

settings

List of method settings (see Details)

Details

The following settings are implemented

"default"

no options

References

Examples

Run this code
# Generate some example data
data <- data.frame(
  yi = c(0.2, 0.3, 0.1, 0.4, 0.25),
  sei = c(0.1, 0.15, 0.08, 0.12, 0.09)
)

# Apply pcurve method
result <- run_method("pcurve", data)
print(result)

Run the code above in your browser using DataLab