chrchang / plink-ng

A comprehensive update to the PLINK association analysis toolset. Beta testing of the first new version (1.90), focused on speed and memory efficiency improvements, is finishing up. Development is now focused on building out support for multiallelic, phased, and dosage data in PLINK 2.0.
https://www.cog-genomics.org/plink/2.0/
416 stars 126 forks source link

Error: Duplicate phenotype/covariate ID #273

Closed AnjeGrobler closed 4 months ago

AnjeGrobler commented 5 months ago

Good day.

I am having the following problem when trying to run a GWAS: At first, I had a similar issue to someone on this platform: Options in effect: plink --adjust --bfile Kids_Merged --ci 0.95 --covar LR_GWAS_MDD.txt --linear --out Thalamus_model2 --pheno Thalamus_MDD.txt Note: No phenotypes present. Warning: Skipping --linear since # variables >= # samples.

Then I used your feedback: Only samples with no missing covariates are included in the linear regression. It looks like practically all of your samples have covariates which are interpreted as missing by plink 1.9. (If this is because you have a categorical covariate, plink 2.0 might work.)

plink2 --bfile Kids_Merged --linear --adjust --ci 0.95 --pheno Thalamus_MDD.txt --covar LR_GWAS_MDD.txt --out Thalamus_model2 Error: Duplicate phenotype/covariate ID 'thalamus'.

Then used your advice again: By default, if you have a phenotype in your .fam file, plink 2.0 will process that in addition to any phenotype(s) in your --pheno file. You can use --pheno-names to select a subset of these phenotypes. You can add a header line to your --pheno file which assigns a suitable name (make it start with "FID IID" or "#FID IID" to make plink happy), or you can also use --no-pheno to ignore the phenotype in the .fam file (this won't ignore --pheno).

However, when I tried running it by including --no-pheno, it did not make any difference: Error: Duplicate phenotype/covariate ID 'thalamus'.

Do you have any advice for me, please?

Thank you. Kind regards, Anje Grobler (South Africa)

chrchang commented 4 months ago

Usage questions should be posted in the plink2-users Google group (https://groups.google.com/g/plink2-users ).