Skip to main content

Zigo: Sex Checking by Zigosity Distributions

A command-line tool for sex inference from genomic data. This tool uses a distilled polynomial equation to predict genetic sex from SNP zygosity distributions and can compare predictions with provided PED files.

Installation

We are working on publishing this package to PyPI. In the meantime, you can install the latest version directly from the repository using pip:

pip install git+https://github.com/AI-sandbox/zigo.git

Key Features

  • Genetic Sex Prediction: Accurately predicts genetic sex from genomic data using a machine learning model
  • PED File Integration: Optional comparison with provided sex information from PED files (requires "Individual ID" and "Gender" columns)
  • Comprehensive Logging: Detailed logs of the analysis process

Usage

zigo -i INPUT_FILE -o OUTPUT_DIR [--ped PED_FILE]

Arguments

  • -i, --input: Path to the genomic input file (.vcf, .vcf.gz, .bed, .pgen)
  • -o, --output: Directory for saving results
  • --ped: (Optional) Path to the PED file containing 'Individual ID' and 'Gender' columns

Input Format Requirements

  • Genomic Data: Supports .bed, .pgen, and includes a high-performance C-based reader for .vcf and .vcf.gz.
  • PED File: Tab-separated file with at least two columns:
    • 'Individual ID': Sample identifiers matching those in the genomic data
    • 'Gender': Sex information coded as 1 (male) or 2 (female)

Output Files

  • results.sexcheck: Main results file with sex predictions, containing the following columns:

    • FID: Family ID (same as IID in this implementation)
    • IID: Individual ID
    • SID: Sample ID (same as IID in this implementation)
    • PEDSEX: Sex as provided in the PED file (1=male, 2=female, NA=not available)
    • SNPSEX: Predicted sex from SNP data (1=male, 2=female)
    • STATUS: Comparison result ("OK" if PEDSEX matches SNPSEX, "PROBLEM" if they differ)
    • F: Probability score for the predicted sex label

    Columns related to Y chromosome have been skipped.

  • results.nosex: List of samples with no sex information

  • sexcheck.log: Detailed log of the analysis process

License

This project is licensed under the Apache License 2.0 - see the LICENSE file for details.

Cite

If you use Zigo in your research, please cite the source code.

📝 Note: Preprint will be published soon! Once published, we will update this section with the official citation.

In the meantime, please cite the repository as follows:

BibTeX:

@misc{zigo_2026,
  author = {Oscar Molina-Sedano, Daniel Mas Montserrat and Alexander Ioannidis},
  title = {Zigo: Sex Checking by Zigosity Distributions},
  year = {2026},
  publisher = {GitHub},
  journal = {GitHub repository},
  howpublished = {\url{[https://github.com/AI-sandbox/sex-check](https://github.com/AI-sandbox/sex-check)}}
}

Metadata

Release files for zigo 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for zigo 0.1.2
File Size Uploaded Provenance Actions
zigo-0.1.2.tar.gz 23.1 kB Without provenance Details for zigo-0.1.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for zigo 0.1.2
File Interpreter ABI Platform Actions
zigo-0.1.2-py3-none-any.whl Python 3 none any Details for zigo-0.1.2-py3-none-any.whl

Total release size: 45.4 kB

Release files / zigo-0.1.2.tar.gz

Download URL zigo-0.1.2.tar.gz
Size 23.1 kB
Tags Source
SHA-256 checksum
How to use checksums
b2fe793d3645f988c76cf32a0210fadd4841417ce71439b07c9ccb9fef768b63
BLAKE2b-256 checksum
How to use checksums
dbc85e94707d90079b8e466684269b4967e60bdd5ed93dffb1c150f0e13bf8f3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.10.9

Release files / zigo-0.1.2-py3-none-any.whl

Download URL zigo-0.1.2-py3-none-any.whl
Size 22.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
3127add59ea1743c4c8f41805f08ce034bbef7ba0213db7e875e3067399f60eb
BLAKE2b-256 checksum
How to use checksums
f04c41cfb23e89f7d76d0f8ab7e47b36045ebcb2025153d37fab15aa3b559623
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.10.9

Security for zigo 0.1.2

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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page