Learn R Programming

flatness (version 0.1.4)

BH_procedure: Multiple statistical hypothesis testing with the Benjamini-Hochberg procedure

Description

This function applies the procedure described in Benjamini & Hochberg (1995) for controlling the False Discovery Rate in multiple statistical hypothesis testing.

Usage

BH_procedure(pvalues, alpha = 0.01, ...)

Arguments

pvalues

a vector of p-values, with length N

alpha

a numeric between 0 and 1

...

same arguments as in function base::sort, except "index.return" which is set to TRUE.

Value

A named listed with entries:

  • H0: a logical vector of length N. The nth entry has value TRUE if the null hypothesis associated with the nth p-value is not rejected and FALSE otherwise.

  • pk: the decision threshold. A p-value under this threshold leads to rejection of the associated null hypothesis.

  • alpha: the chosen significance level

  • pvalues: the vector of p-values provided to apply the Benjamini-Hochberg procedure.

Details

The procedure works as follows. Let N p-values \(p_i\) (with \(i=1,\ldots,N\)) and a significance level \(\alpha\). The decision threshold is \(p_k\) where \(k = max(i;p_{(i)} <= \alpha \frac{i}{N})\) where \(p_{(i)}\) are the sorted p-values \(p_i\). For every test with \(p_i \le p_k\), the null hypothesis is rejected. By convention \(p_{(0)} = 0\).

References

Benjamini, Y., & Hochberg, Y. (1995). "Controlling the false discovery rate: a practical and powerful approach to multiple testing." Journal of the Royal statistical society: series B (Methodological), 57(1), 289-300. doi:https://doi.org/10.1111/j.2517-6161.1995.tb02031.x