Skip to main content
# Ypredict
**Ypredict** is a python based software package that predicts y chromosome haplogroup. Here, I use calculate rank method to automatically find the most likely y haplogroup. For each y haplogroup, I give two mark (T or F) according their snp calling state. For Example, if the haplogroup O2a1a1a2a1 in isogg (<https://isogg.org/tree/>) haplogroup tree has six snps, five snps was observed. If the ratio is 5/6 >= 0.2, I give the T mark. Else, F mark. For each haplogroup, I calculate the number of T mark as n_T, nonexist as n_F, along the routine from the 'Y' haplogroup to this haplogroup(rank = (n_T**2)/(n_T + n_F)). If the rank same, the max number of n_T of the haplogroup will be the most likely haplogroup. If rank and n_T are both the same, then ramdomly select the one of matched haplogroup.
* The current version is 0.0.1

# Dependence
* biopython(<https://biopython.org/wiki/Download>)
* GATK(<https://software.broadinstitute.org/gatk/download/>)

# Getting Started
***
## Step1
Download y haplogroup tree from isogg. Then, filter snp by snpfilter.py. In this step, hotspot and backmutate snp will be removed. Finally, two files map.json and ref_vcf.gz will be generated. Importantly, Y chromosome fasta file will use in this step(test/Y.fasta), it can be downloaded from NCBI or get from hg38 reference genome using bedtools.
`snpfilter.py -snp snp14.3.csv -y Y.fasta`
## Step2
In this step, we will use the file ref_vcf.gz generated by the step1 to make snp calling using gatk3.8 UnifiedGenotyper module. Critically, we use hg38 reference genome in this step.

`java -Xmx32g -jar GenomeAnalysisTK.jar -T UnifiedGenotyper
-R hg38.fa -I *.bam -o y.vcf.gz
--intervals chrY
-ploidy 1
--output_mode EMIT_ALL_SITES --genotyping_mode GENOTYPE_GIVEN_ALLELES
--alleles ref_vcf.gz `
## Step3
Y chromosome haplogroup can be predicted by ypredict.py. In the this step, the script will automatically output the most likely haplogroup. The final result can be seen in ypredict.txt. More detail output writed in ystatistics.csv.

`ypredict.py -vcf y.vcf.gz -s hfspecial.xlsx -m map.json`

If you need to update y haplogroup tree file downloaded from isogg, you can redo step1 and get an updated map.json.
# Install
`git clone https://github.com/N-damo/ypredict-master.git`

`python setup.py install`
or `pip install ypredict`

Metadata

Release files for Ypredict 0.1.3

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

Source distribution (sdist)

Source distribution for Ypredict 0.1.3
File Size Uploaded Provenance Actions
Ypredict-0.1.3.tar.gz 9.2 MB Without provenance Details for Ypredict-0.1.3.tar.gz

Release files / Ypredict-0.1.3.tar.gz

Download URL Ypredict-0.1.3.tar.gz
Size 9.2 MB
Tags Source
SHA-256 checksum
How to use checksums
f8aecfca064dfb08c28bb047f376b2a4d3efa5fb1be938d624b0d3afe916952d
BLAKE2b-256 checksum
How to use checksums
05505f5bfac4e2da73442b79a14cc21474bc16776a44323b606fa9abd64d4fa2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.4.2 requests/2.18.4 setuptools/39.1.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/2.7.15

Security for Ypredict 0.1.3

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