phenosign
phenosign is a Python library for analyzing pairwise relationships between Human Phenotype Ontology (HPO) features in GA4GH Phenopacket cohorts.
It provides two complementary analyses:
- Pairwise association analysis, which measures associations between binary phenotype annotations using the phi coefficient and Fisher's exact test.
- Target-specific synergy analysis, which evaluates whether a pair of phenotype features provides joint information about a predefined target beyond the information provided by the individual features.
Installation
pip install phenosign
Features
- Construction of phenotype matrices from GA4GH Phenopackets, with separate representation of observed, excluded, and unreported HPO annotations
- Ontology-aware propagation of phenotype annotations
- Pairwise phenotype association analysis using the phi coefficient, Fisher's exact test, and Benjamini–Hochberg correction, with exclusion of ancestor–descendant HPO term pairs
- Mutual-information-based phenotype-pair synergy analysis with permutation testing and Benjamini–Hochberg correction, supporting targets such as disease diagnosis, variant effect, and sex
- Tabular results and interactive heatmaps, including contingency counts, effective sample sizes, adjusted p-values, and publication provenance where available
Quickstart
from pathlib import Path
from google.protobuf.json_format import Parse
from phenosign import (
PhenotypeDatasetBuilder,
HPOCorrelationAnalyzer,
)
# Load phenopackets
phenopacket_dir = Path("path/to/your/fbn1_phenopackets/")
phenopackets = []
for file_path in phenopacket_dir.glob("*.json"):
with open(file_path, "r", encoding="utf-8") as f:
data: str = f.read()
phenopacket: Phenopacket = Parse(data, Phenopacket())
phenopackets.append(phenopacket)
# Build dataset
dataset = PhenotypeDatasetBuilder(phenopackets).build(build_gpsea_cohort=False)
# Run correlation analysis
analyzer = HPOCorrelationAnalyzer(dataset)
results = analyzer.compute_correlation_matrix()
results.result_table.head()
For complete workflows, synergy analysis, visualization options, and API details, see the Documentation.
Metadata
Release files for phenosign 0.1.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| phenosign-0.1.5.tar.gz | 38.4 kB | Without provenance | Details for phenosign-0.1.5.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| phenosign-0.1.5-py3-none-any.whl | Python 3 | none | any | Details for phenosign-0.1.5-py3-none-any.whl |
Total release size: 83.9 kB
Release files / phenosign-0.1.5.tar.gz
| Download URL | phenosign-0.1.5.tar.gz |
|---|---|
| Size | 38.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
534db36b67462b4cee76e2d6fc807e2ad639b056babedac8a50c7293e182fb87
|
|
BLAKE2b-256 checksum How to use checksums |
03163a89a2270aa762fb4ee6fbee8474dc162c6b75bd9c59be542079e4e5b760
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.10.20
|
Release files / phenosign-0.1.5-py3-none-any.whl
| Download URL | phenosign-0.1.5-py3-none-any.whl |
|---|---|
| Size | 45.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c0d3f44ad694a8cf77dbfdce6476899a4b3a65fa626d9b6997b204a66e168035
|
|
BLAKE2b-256 checksum How to use checksums |
084c52d7d60880d3c3fd8ea9d0c81c5e7d1e81b38c8bef4ed811ac7c9be8e119
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.10.20
|
Security for phenosign 0.1.5
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.