Skip to main content

A package to perform Cauchy combination test.

Project description

Cauchy combination test

This is a package performs Cauchy combination test (cct) developed by Liu et al. (2025). The code is the python reimplementation of CCT.R in STAAR project.

Tutorial

To perform the Cauchy combination test, user need to supply a numpy array with p-values. Several quality controls will be conducted, including check NaN value(s) and all the p-values are between 0 and 1 (exactly 0 and 1 are not allowed). User can also supply weight for each p-value for the test. Similarly, quality controls will be conducted, including check: NaN values, negative value, the sum of all weight values is not 1. Error will be raised if violating the these quality controls, so check your input before perform the analysis.

Example run

Test with p-value array only, all the p-values will have exactly same weight.

>>> from cauchy_combination_test import cct
>>> pval_arr = np.array([0.43, 0.86, 0.003, 0.0001, 1E-4, 0.19])
>>> cct(pval_arr)
0.00029510164688062446

Test with p-value array and weight.

>>> from cauchy_combination_test import cct
>>> pval_arr = np.array([0.43, 0.86, 0.003, 0.0001, 1E-4, 0.19])
>>> weight_arr = np.array([0.31, 0.35, 0.01, 0.01, 0.01, 0.31])
>>> cct(pval_arr, weight_arr)
0.004934287256275538

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cauchycombt-0.0.1.tar.gz (3.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cauchycombt-0.0.1-py3-none-any.whl (2.8 kB view details)

Uploaded Python 3

File details

Details for the file cauchycombt-0.0.1.tar.gz.

File metadata

  • Download URL: cauchycombt-0.0.1.tar.gz
  • Upload date:
  • Size: 3.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.14

File hashes

Hashes for cauchycombt-0.0.1.tar.gz
Algorithm Hash digest
SHA256 fdb811cd46472a3b936e47e72c07bedc9931f443c8fb8f041fc29b905d4c94ec
MD5 dc713ce54d14a64320fddb5f70542287
BLAKE2b-256 dfebf3f51b80f9291283156426faa47f57f213224f283dc6e7291c4f1f4c6ae0

See more details on using hashes here.

File details

Details for the file cauchycombt-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: cauchycombt-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 2.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.14

File hashes

Hashes for cauchycombt-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e639a21b397a34160bb88a3e3b0902d08cb6ffacecd896d4e70c3ad7b55fee65
MD5 ca16135e8e10cbaacb9e5d69ef7cdcf7
BLAKE2b-256 e06970af9c2dbd05f0f9e7daf7819a4e3027ae051e41beab98c293051dd6de61

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page