p_edgington: Edgington's method

View source: R/pfun_edgington.R

p_edgingtonR Documentation

Edgington's method

Description

Edgington’s method for combining p-values across studies. The method forms a sum of individual study p-values and evaluates it against the exact or approximate null distribution.

Under the global null hypothesis, the null distribution of the sum is given by the Irwin–Hall distribution. For a weighted generalization of this procedure, see p_edgington_w.

Usage

p_edgington(
  estimates,
  SEs,
  mu = 0,
  heterogeneity = "none",
  phi = NULL,
  tau2 = NULL,
  check_inputs = TRUE,
  input_p = "greater",
  output_p = "two.sided",
  approx = TRUE
)

Arguments

estimates

Numeric vector of study-level effect estimates.

SEs

Numeric vector of corresponding standard errors.

mu

Numeric scalar or vector of null values for the overall effect (default: 0).

heterogeneity

One of c("none", "additive", "multiplicative"). If heterogeneity = "none", p-values are returned for the passed SEs without any adaptation. If heterogeneity = "additive", the standard errors are reassigned the value \sqrt{SEs^2 + \text{tau2}} before computation of the p-values. If heterogeneity = "multiplicative", the standard errors SEs are multiplied by \sqrt{\text{phi}} before computation of the p-values. Defaults to "none".

phi

A numeric vector of length 1. Must be finite and larger than 0. The square root of the argument is used to scale the standard errors.

tau2

A numeric vector of length 1. Additive heterogeneity parameter.

check_inputs

Either TRUE (default) or FALSE. Indicates whether or not to check the input arguments. The idea of this argument is that if the function is called a large amount of times in an automated manner as for example in simulations, performance might be increased by not checking inputs in every single iteration. However, setting the argument to FALSE might be dangerous.

input_p

Type of study-level p-values used in the combination: "greater" (default), "less", or "two.sided". If "greater" or "less", one-sided p-values are combined.

output_p

Character string specifying the combined p-value type: "two.sided" (default) or "one.sided". This controls whether the final combined p-value is symmetrized. Note: To construct valid p-value functions, the confMeta

approx

Logical (default TRUE). If TRUE, use a normal approximation for the sum of p-values when k\geq 12 to avoid numerical overflow issues.

Details

The classical Edgington statistic is defined for k studies as

S = \sum_{i=1}^k p_i,

where p_i are individual study p-values. Under the global null hypothesis, each p_i is assumed to be uniformly distributed on [0, 1].

Important note on orientation: Edgington's method is orientation-invariant. The combined p-value is symmetric with respect to the direction of the one-sided p-values (controlled by the input_p argument).

Specifically, computing the Edgington combined p-value for the "greater" alternative results in 1 minus the Edgington combined p-value for the "less" alternative.

Value

A numeric vector of combined p-values corresponding to each value of mu.

Null Distribution and Approximation

The combined p-value, p_E, is the probability of observing a sum less than or equal to S under the null hypothesis. This is computed in one of two ways:

  • Exact Method: The function uses the exact Irwin-Hall distribution to compute the combined p-value:

    p_E = \frac{1}{k!} \sum_{j=0}^{\lfloor S \rfloor} (-1)^j \binom{k}{j} (S - j)^k

  • Normal Approximation: For a large number of studies (k \geq 12), the distribution of the sum is approximated by a Normal distribution with:

    \mathrm{E}[S] = \frac{k}{2}

    \mathrm{Var}(S) = \frac{k}{12}

Output p-value

The final output depends on the output_p and input_p arguments:

  • If output_p = "two.sided" (the default) and the inputs are one-sided (input_p is "greater" or "less"), the function combines the one-sided p-values to obtain the intermediate combined p-value p_c, and returns a symmetrized, two-sided p-value: p_{2s} = 2 \min(p_c, 1 - p_c).

  • If output_p = "one.sided", the function returns the inherently one-sided combined p-value p_c directly, without symmetrization.

  • If input_p is "two.sided", the input p_i are already two-sided, and no further symmetrization is applied.

References

Edgington, E. S. (1972). An additive method for combining probability values from independent experiments. The Journal of Psychology, 80(2): 351-363. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1080/00223980.1972.9924813")}

Held, L, Hofmann, F, Pawel, S. (2025). A comparison of combined p-value functions for meta-analysis. Research Synthesis Methods, 16:758-785. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1017/rsm.2025.26")}

See Also

Other p-value combination functions: p_edgington_w(), p_fisher(), p_hmean(), p_pearson(), p_stouffer(), p_tippett(), p_wilkinson()

Examples

# Simulating estimates and standard errors
n <- 15
estimates <- rnorm(n)
SEs <- rgamma(n, 5, 5)

# Set up a vector of means under the null hypothesis
mu <- seq(
  min(estimates) - 0.5 * max(SEs),
  max(estimates) + 0.5 * max(SEs),
  length.out = 100
)

# Using Edgington's method to calculate the combined p-value
p_edgington(
    estimates = estimates,
    SEs = SEs,
    mu = mu,
    heterogeneity = "none",
    output_p = "two.sided",
    input_p = "greater",
    approx = TRUE
)

confMeta documentation built on June 10, 2026, 1:06 a.m.