This is a test version of Biostars. For the public version, visit https://www.biostars.org.
plink update .bim question

Hello,

I am trying to update the outdated rsids in a plink .bim file based on .bim end chrom position via a file I created on ucsc genome browser. The ucsc file all-snp.csv I generated has col1 (X.chrom), col2 (chromEnd) col3 (updated rsid) and the faulty.bim file has col1 (x), col2 (old rsid), col4 (chromEnd):

system("./plink --file faulty.bim --update-name all-snp.csv 2 4 --make-bed -out correctedBim.bim")

With the above command, I am getting an error:

Error: Failed to open faulty.bim.map

Would anybody be able to guide me as far as what I am doing wrong? Thank you.

plink chrom update rsid

1 answer

  1. You need to use --bim, not --file, here. --file specifies a .ped + .map file pair, not a single .bim file without anything accompanying it.

  2. Similarly, you need to use --make-just-bim instead of --make-bed.

Thank you so much for the quick and helpful reply!

Log in to answer this question.