Mixed genotype phasing is performed based on the number of reads supporting
each allele at an heterozygous site. The phasing will be run nsim
times and
phased data with the highest correlation between MAF from raw data and MAF
from phased data will be retained.
phase_mixed_genotypes(snpdata, nsim = 100L)
a SNPdata
object with an additional table named as Phased. This
object will contain the phased genotype data
When both alleles are not supported by any read or the total number of reads supporting both alleles at a given site is < 5, the genotype will be phased based on a Bernoulli distribution using the MAF as a parameter. Similarly, when the total number of reads is > 5 and the number of reads supporting one of the allele is not 2 times the number of the other, the genotype is phased using a Bernoulli distribution.
if (FALSE) { # \dontrun{
snpdata <- phase_mixed_genotypes(snpdata)
} # }