Entering edit mode
3.5 years ago
eyb
▴
250
Hello. I am trying to extract data from .bed file using the following command:
./plink_linux_i686_20200616/plink --bed study.bed --bim study.bim --fam study.fam --keep-fam ii.txt --make-bed --out ii
It works for affected samples, but when I try to do the same for controls it says that there are 0 samples left after filtration. Could it be because the order of control samples is different in --keep-fam txt file and fam file itself? The order of affected samples and samples in txt file matches.
Order does not matter.
If you need help figuring out what happened, please post the .log file from the problematic run, along with the top lines from your .fam file and the —keep-fam file you used.
Here is the plink log from problematic run.
Here is the top of the fam file:
here is --keep-fam txt:
Look closely at your --keep-fam file. The IDs are slightly off: "204117..." instead of "20417...".
Thanks, but at the top of the fam file are IDs that I already extracted. IDs that I need are somewhere in the middle.
The number of digits is different. From what you have posted, there is every reason to believe you made a mistake creating this --keep-fam file, and your problem will go away when you fix that mistake.