This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Changing Genome Coordinates For Vcf

I have a VCF file which uses hg18/NCBI36 coordinates. I would like to convert the coordinates to GRCh37 to compare the variants with a more recent data set. Is there a tool to perform this conversion? One way to do it would be to convert the variants to BED then use UCSC liftOver. Before writing this myself, I thought I should check if someone else has solved this problem first.

vcf

2 answers

GATK provides a tool for this:

http://www.broadinstitute.org/gsa/wiki/index.php/LiftOverVCF.pl

you will find several posts on this matter if you just search BioStar for "hg18 hg19" for instance.

UCSC liftOver and Ensembl Assembly Converter are the most suggested options.

Hi Jorge, thanks for the pointer but I am specifically looking for a tool to convert a VCF file. I believe that liftover/ensembl require BED or GFF input. It is not a difficult conversion but it would be nice if a standard tool existed to do this.

oh, I see. unfortunately I don't know of such tool that would translate coordinates from a VCF file directly, so I guess you'll have to extract them yourself and then upgrade them using any of the mentioned tools. for the coordinates extraction theres a post on seqanswers describing some awk and sed scripting that may be helpful: http://seqanswers.com/forums/showthread.php?t=9132

Log in to answer this question.