Hi all,
I am trying to update my .fam file with newly acquired phenotypes for my subjects, but am running into a few problems.
I am trying to use plink 2 to update these phenotypes listed in a txt file. Few column examples of format of txt file:
FID IID HC MDD PTSD Bipolar
82 PB001 MDD
3 PB005 MDD
I am trying to update my .fam file phenotype column using this plink2 scirpt:
plink2 --bfile chr1_ped --no-fid --pheno phenoPRS6_widFID.txt --pheno-name
I used --no-fid as my .fam file is using subject ID's as FIDs. Example of format of .fam file:
1_PB068 1_PB068 0 0 0 -9
1_PB286 1_PB286 0 0 0 -9
2_PB039 2_PB039 0 0 0 -9
This error was obtained upon running plink2:
Error: No entries in phenoPRS6_widFID.txt correspond to loaded sample IDs.
and I'm sure this error is occuring because my .fam file is using subject ID's as FIDs and also the format of subject ID is #_subjectID. See example of .fam format above.
Questions:
- What's the best way I can update my subject IDs excluding the #_ ?
- How then can I update my fiid's to match the FID's in the txt pheno file?
- Should my script to update phenotypes work after fixing these two columns? If not, what should I change in the script?
- Does Plink2 truly work on categorical phenotypes using plink2 work? Do phenoytpes in fact have to be listed as numerical (despite the guide saying it can be categorical?)
Lots of questions, I know. Perhaps simple answers. Please help, if you can!
Thanks.
fid
fam
plink
phenotype