I've got .bed/.bim/.fam SNP files and am using physical bp positions to extract SNP subsets in PLINK (version 1.9). I got my coordinates from UCSC Table Browser so some of the chromosome IDs are unusual, like "6_ssto_hap7" or "Un_gl000211".
I tried using
--allow-extra-chr 0 to include these but it doesn't seem to be working as I still get the same error
Error: Invalid chromosome code on line 938486 of --extract range file.
(Line 938486 is where the unusual chromosome IDs start)
I've been using this command:
plink --bfile <filename> --extract range <coordinates.txt> --make-bed --out <newfile> --allow-extra-chr 0
If I delete all the coordinates with the unusual chromsome IDs, I can successfully extract SNPs.
Any suggestions to fix this?