# MultiTest -- Global Tests for Multiple Hypothesis
MultiTest includes several techniques for multiple hypothesis testing:
- ``MultiTest.hc`` Higher Criticism
- ``MultiTest.hcstar`` Higher Criticism with limited range proposed in [1]
- ``MultiTest.hc_jin`` Higher Criticism with limited range proposed as proposed in [3]
- ``MultiTest.berk_jones`` Berk-Jones statistic
- ``MultiTest.fdr`` False-discovery rate with optimized rate parameter
- ``MultiTest.minp`` Minimal P-values as in Bonferroni style inference
- ``MultiTest.fisher`` Fisher's method to combine P-values
In all cases, one should reject the null for large values of the test statistic.
## Example:
```
import numpy as np
from scipy.stats import norm
from multitest import MultiTest
p = 100
z = np.random.randn(p)
pvals = 2*norm.cdf(-np.abs(z)/2)
mtest = MultiTest(pvals)
hc, p_hct = mtest.hc(gamma = 0.3)
bj = mtest.berk_jones()
ii = np.arange(len(pvals))
print(f"HC = {hc}, Indices of P-values below HCT: {ii[pvals <= p_hct]}")
print(f"Berk-Jones = {bj}")
```
## Use cases:
This package was used to obtain evaluations reported in [5] and [6].
## References:
[1] Donoho, David. L. and Jin, Jiashun. "Higher criticism for detecting sparse hetrogenous mixtures." The Annals of Statistics 32, no. 3 (2004): 962-994.
[2] Donoho, David L. and Jin, Jiashun. "Higher critcism thresholding: Optimal feature selection when useful features are rare and weak." proceedings of the national academy of sciences, 2008.
[3] Jin, Jiashun, and Wanjie Wang. "Influential features PCA for high dimensional clustering." The Annals of Statistics 44, no. 6 (2016): 2323-2359.
[4] Amit Moscovich, Boaz Nadler, and Clifford Spiegelman. "On the exact Berk-Jones statistics and their p-value calculation." Electronic Journal of Statistics. 10 (2016): 2329-2354.
[5] Donoho, David L., and Alon Kipnis. "Higher criticism to compare two large frequency tables, with sensitivity to possible rare and weak differences." The Annals of Statistics 50, no. 3 (2022): 1447-1472.
[6] Kipnis, Alon. "Unification of rare/weak detection models using moderate deviations analysis and log-chisquared p-values." Statistica Scinica 2025.
Raw data
{
"_id": null,
"home_page": "https://github.com/alonkipnis/higher-criticism-test",
"name": "multiple-hypothesis-testing",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.6",
"maintainer_email": null,
"keywords": null,
"author": "Alon Kipnis",
"author_email": "alonkipnis@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/bd/14/f1d377b1431bf55492fb5bf8558fd2f338b8c4dc986399274e9afd5ea2ce/multiple_hypothesis_testing-0.1.12.tar.gz",
"platform": null,
"description": "# MultiTest -- Global Tests for Multiple Hypothesis\n\nMultiTest includes several techniques for multiple hypothesis testing:\n- ``MultiTest.hc`` Higher Criticism\n- ``MultiTest.hcstar`` Higher Criticism with limited range proposed in [1]\n- ``MultiTest.hc_jin`` Higher Criticism with limited range proposed as proposed in [3]\n- ``MultiTest.berk_jones`` Berk-Jones statistic\n- ``MultiTest.fdr`` False-discovery rate with optimized rate parameter\n- ``MultiTest.minp`` Minimal P-values as in Bonferroni style inference\n- ``MultiTest.fisher`` Fisher's method to combine P-values\nIn all cases, one should reject the null for large values of the test statistic.\n\n## Example:\n```\nimport numpy as np\nfrom scipy.stats import norm\nfrom multitest import MultiTest\n\np = 100\nz = np.random.randn(p)\npvals = 2*norm.cdf(-np.abs(z)/2)\n\nmtest = MultiTest(pvals)\n\nhc, p_hct = mtest.hc(gamma = 0.3)\nbj = mtest.berk_jones()\n\nii = np.arange(len(pvals))\nprint(f\"HC = {hc}, Indices of P-values below HCT: {ii[pvals <= p_hct]}\")\nprint(f\"Berk-Jones = {bj}\")\n```\n\n## Use cases: \nThis package was used to obtain evaluations reported in [5] and [6].\n\n## References:\n[1] Donoho, David. L. and Jin, Jiashun. \"Higher criticism for detecting sparse hetrogenous mixtures.\" The Annals of Statistics 32, no. 3 (2004): 962-994.\n[2] Donoho, David L. and Jin, Jiashun. \"Higher critcism thresholding: Optimal feature selection when useful features are rare and weak.\" proceedings of the national academy of sciences, 2008.\n[3] Jin, Jiashun, and Wanjie Wang. \"Influential features PCA for high dimensional clustering.\" The Annals of Statistics 44, no. 6 (2016): 2323-2359.\n[4] Amit Moscovich, Boaz Nadler, and Clifford Spiegelman. \"On the exact Berk-Jones statistics and their p-value calculation.\" Electronic Journal of Statistics. 10 (2016): 2329-2354.\n[5] Donoho, David L., and Alon Kipnis. \"Higher criticism to compare two large frequency tables, with sensitivity to possible rare and weak differences.\" The Annals of Statistics 50, no. 3 (2022): 1447-1472.\n[6] Kipnis, Alon. \"Unification of rare/weak detection models using moderate deviations analysis and log-chisquared p-values.\" Statistica Scinica 2025.\n",
"bugtrack_url": null,
"license": null,
"summary": "Several methods of combining P-values",
"version": "0.1.12",
"project_urls": {
"Download": "https://github.com/alonkipnis/higher-criticism-test",
"Homepage": "https://github.com/alonkipnis/higher-criticism-test"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "29235f4710659b2d138d3281a0979264ed55e850d04948920943ec989605ee95",
"md5": "b52f2761dbf0426b1708e56551038418",
"sha256": "b3b87200cc3c2e5429d5015559140d368a77864964c563b4032e8e1558c0fff6"
},
"downloads": -1,
"filename": "multiple_hypothesis_testing-0.1.12-py3-none-any.whl",
"has_sig": false,
"md5_digest": "b52f2761dbf0426b1708e56551038418",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.6",
"size": 6921,
"upload_time": "2024-07-21T18:48:01",
"upload_time_iso_8601": "2024-07-21T18:48:01.408082Z",
"url": "https://files.pythonhosted.org/packages/29/23/5f4710659b2d138d3281a0979264ed55e850d04948920943ec989605ee95/multiple_hypothesis_testing-0.1.12-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "bd14f1d377b1431bf55492fb5bf8558fd2f338b8c4dc986399274e9afd5ea2ce",
"md5": "ffb5646571bd5bc2723431dde1955533",
"sha256": "a4cc8b851dfdc8d17fb6482e24c9ce092023142870e2c0167ab471069fa70160"
},
"downloads": -1,
"filename": "multiple_hypothesis_testing-0.1.12.tar.gz",
"has_sig": false,
"md5_digest": "ffb5646571bd5bc2723431dde1955533",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.6",
"size": 6272,
"upload_time": "2024-07-21T18:48:02",
"upload_time_iso_8601": "2024-07-21T18:48:02.816986Z",
"url": "https://files.pythonhosted.org/packages/bd/14/f1d377b1431bf55492fb5bf8558fd2f338b8c4dc986399274e9afd5ea2ce/multiple_hypothesis_testing-0.1.12.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-07-21 18:48:02",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "alonkipnis",
"github_project": "higher-criticism-test",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "multiple-hypothesis-testing"
}