Good Morning Nandini: You can convert your VCF files to bed format.
If your VCF files follow the format: http://www.1000genomes.org/node/101 This awk command will convert them to bed format (assuming | is not a character found in the vcf fields): grep -v "^#" yourFile.vcf | awk '{printf "%s\t%d\t%d\t%s|%s|%s|%s|%s|%s\n", $1,$2-1,$2,$3,$4,$5,$6,$7,$8}' > yourFile.bed liftOver yourFile.bed hg19ToHg18.over.chain newFile.bed unMapped Then, from that lifted bed file back to vcf: awk '{printf "%s\t%d\t%s\n", $1,$2+1,$4}' newFile.bed | tr '[|]' '[\t]' > newFile.vcf You may need to adjust these awk statements depending upon the exact format of your vcf file. --Hiram Nandini B wrote: > Hello, > I am trying to use liftover for my SNPs from hg19 to hg18. But I have my SNP > files in either gff3 format or vcf (v4.1). Is it possible to use these files > to execute the command > liftOver -gff oldFile.gff3 hg19ToHg18.over.chain newFile.gff3 unMapped or > > liftOver -vcf oldFile.vcf hg19ToHg18.over.chain newFile.vcf unMapped > > Or do I have to convert them into BED format, if so, is there any tool that > could do this ? > > > Thank you, > Warm Regards, > > Nandini Badarinarayan _______________________________________________ Genome maillist - [email protected] https://lists.soe.ucsc.edu/mailman/listinfo/genome
