This is a test version of Biostars. For the public version, visit https://www.biostars.org.
HWE test different result according Pheno data

Hello,

In my ped files (2 files : one Recessif and other Dominant) I have all the information same, except for phenotype data, content is constructed with R, as you can see same information except phenotype (1 or 2 as value)

ped <- data.frame(
  FID = rep(1:n),
  IID =  rep(1:n),
  DadID = 0,
  MomID = 0,
  Sex =  sample(1:2, cohortSize, replace = TRUE),
  Phenotype = -9)

pedD <- ped
pedD$Phenotype <- phenoD
pedD <- cbind(pedD, genoC)

pedR <- ped
pedR$Phenotype <- phenoR
pedR<- cbind(pedR, genoC)

GenoC is containing 0,1 or 2 values. I'm surprised, when i request HWE test, to have different result between both files :

plink --file snpchr1_R --maf 0.05 --hwe 0.000001 --mind 0.01 --geno 0.01 --make-bed --out clean_snpchr1_R

plink --file snpchr1_D --maf 0.05 --hwe 0.000001 --mind 0.01 --geno 0.01 --make-bed --out clean_snpchr1_D

--hwe: 11 variants removed due to Hardy-Weinberg exact test.

--hwe: 1 variant removed due to Hardy-Weinberg exact test.

As i understood, HWE test is testing genotype frequency translated to allele frequency which in turn is used to recalculate HWE according P² Q² and 2PQ, and making chisq.test between both value(calculated, expected). If the p-value <= 0.000001 then the snp should be removed. So only genotypic information are important in this evaluation. How could Pheno values impact this test ?

Thanks a lot.

plink gwas

1 answer

From the plink 1.9 --hwe documentation (https://www.cog-genomics.org/plink/1.9/filter#hwe ):

"with case/control data, cases and missing phenotypes are normally ignored; override this with 'include-nonctrl'".

Note that this behavior was removed in plink 2.0, since plink 2.0 is not restricted to one loaded phenotype.

Log in to answer this question.