AlphaGenes / AlphaPeel

AlphaPeel: calling, phasing, and imputing genotype and sequence data in pedigrees
MIT License
2 stars 11 forks source link

Implement logic test 02: Test basic phasing #137

Closed AprilYUZhang closed 3 months ago

AprilYUZhang commented 9 months ago
$ cat pedigree.txt 
FathersGrandMother 0 0
FathersGrandFather 0 0
MothersGrandMother 0 0
MothersGrandFather 0 0
Mother MothersGrandFather MothersGrandMother
Father FathersGrandFather FathersGrandMother
Progeny Father Mother
$ cat genotype.txt 
FathersGrandMother 1 1 1 0 0 0
FathersGrandFather 2 2 2 2 2 2
MothersGrandMother 2 2 2 2 2 2
MothersGrandFather 0 0 0 1 1 1
Mother  1 1 1 2 2 2
Father  2 2 2 1 1 1
Progeny 1 1 1 1 1 1
$ cat test.phased_geno_prob.txt 

Father 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000
Father 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000
Father 0.0000 0.0000 0.0000 1.0000 1.0000 1.0000
Father 1.0000 1.0000 1.0000 0.0000 0.0000 0.0000

FathersGrandFather 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000
FathersGrandFather 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000
FathersGrandFather 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000
FathersGrandFather 0.9999 0.9999 0.9999 0.9999 0.9999 0.9999

FathersGrandMother 0.0000 0.0000 0.0000 0.9999 1.0000 0.9999
FathersGrandMother 0.3200 0.2001 0.0000 0.0000 0.0000 0.0000
FathersGrandMother 0.6799 0.7999 1.0000 0.0000 0.0000 0.0000
FathersGrandMother 0.0001 0.0001 0.0000 0.0000 0.0000 0.0000

Mother 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000
Mother 1.0000 1.0000 1.0000 0.0000 0.0000 0.0000
Mother 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000
Mother 0.0000 0.0000 0.0000 1.0000 1.0000 1.0000

MothersGrandFather 0.9999 1.0000 0.9999 0.0000 0.0000 0.0000
MothersGrandFather 0.0000 0.0000 0.0000 0.0000 0.2001 0.3200
MothersGrandFather 0.0000 0.0000 0.0000 1.0000 0.7999 0.6799
MothersGrandFather 0.0000 0.0000 0.0000 0.0000 0.0001 0.0001

MothersGrandMother 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000
MothersGrandMother 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000
MothersGrandMother 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000
MothersGrandMother 0.9999 0.9999 0.9999 0.9999 0.9999 0.9999

Progeny 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000
Progeny 0.0000 0.0000 0.0000 1.0000 1.0000 1.0000
Progeny 1.0000 1.0000 1.0000 0.0000 0.0000 0.0000
Progeny 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000
$ cat test.seg_prob.txt 
Father 0.3400 0.4000 0.4999 0.4000 0.3400 0.3040
Father 0.1600 0.1000 0.0001 0.1000 0.1600 0.1960
Father 0.3400 0.4000 0.4999 0.4000 0.3400 0.3040
Father 0.1600 0.1000 0.0001 0.1000 0.1600 0.1960

FathersGrandFather 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500
FathersGrandFather 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500
FathersGrandFather 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500
FathersGrandFather 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500

FathersGrandMother 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500
FathersGrandMother 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500
FathersGrandMother 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500
FathersGrandMother 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500

Mother 0.3040 0.3400 0.4000 0.4999 0.4000 0.3400
Mother 0.3040 0.3400 0.4000 0.4999 0.4000 0.3400
Mother 0.1960 0.1600 0.1000 0.0001 0.1000 0.1600
Mother 0.1960 0.1600 0.1000 0.0001 0.1000 0.1600

MothersGrandFather 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500
MothersGrandFather 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500
MothersGrandFather 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500
MothersGrandFather 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500

MothersGrandMother 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500
MothersGrandMother 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500
MothersGrandMother 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500
MothersGrandMother 0.2500 0.2500 0.2500 0.2500 0.2500 0.2500

Progeny 0.3677 0.3314 0.2395 0.0877 0.0561 0.0702
Progeny 0.0504 0.0320 0.0328 0.0328 0.0320 0.0504
Progeny 0.5118 0.5805 0.6400 0.6400 0.5805 0.5118
Progeny 0.0702 0.0561 0.0877 0.2395 0.3314 0.3677

It would be great to modify this example to make the segregation probabilities clearer (closer to 0 & 1)

IMG_1044