#36 Incorrect MAF calculation


I noticed that the MAF calculation in Haploview happens before any missing trio genotypes are imputed. This can lead to polymorphic SNPs being called as monomorphic.

For example, rs1014201 has an MAF of 0.0 in the CEU population when only looking at the founder subjects. However, one child (NA12752) is heterozygous at this marker (AG) and the father in the family has an uncalled genotype of NN. The mother has a genotype of GG. Haploview (HaploData.linkageToChrom) imputes one of the father’s alleles to get a genotype of AN. Thus, the MAF of this SNP is actually 0.008.

But, Haploview reports the MAF as 0. The problem seems to be in HaploData.java in the prepareMarkerInput method.

double maf;
if (mr != null){
maf = Util.roundDouble(mr.getMAF(),3);
maf = Util.roundDouble((numa2/(numa1+numa2)),3);

The MarkerResult object, mr, comes from the PedFile results that are calculated before linkageToChrom imputes any genotypes. If mr was null, then the ‘else’ statement would be executed and the MAF calculation would be correct.


Log in to post a comment.