How to force merge a VCF files, for different samples?
2
0
Entering edit mode
7.5 years ago
kirannbishwa01 ★ 1.6k

I obtained vcf files from a tool I used. I want to merge them but it was missing some TAG info, which I fixed. Now, I am having somekind of ERROR probably emerging again from HEADER.

Is there a way to force merge vcf files, if not fix the vcf files. I don't really care much about HEADER at this time.

Thanks,

vcf merge SNP genome • 10k views
ADD COMMENT
0
Entering edit mode

I obtained vcf files from a tool I used.

So you used some tool, on some data generated with a technology on some samples, and got vcf files.

I want to merge them but it was missing some TAG info, which I fixed.

You were missing some tag info, which you somehow fixed.

Now, I am having somekind of ERROR probably emerging again from HEADER.

And now, using an unknown tool, you get an error.

You need to add a lot of information to this question. I'm considering closing this because you are just making it impossible to answer.

ADD REPLY
0
Entering edit mode

Hi @WouterDeCoster.

How are you doing? Yeah, I used a a toold called phase to phase my variants, which unfortunately in the recent version had a bug and didn't add PG tag in the header. I have to merge different vcf files that came out of this tool, but I am getting error on every tool that does vcf merge.

I also tried adding PG field using AWK, sed but no luck excepting the error.

I think rest of the DATA on VCF files are good, and I need to do some presentation using this data. I don't have much time to redo the whole analyses (phasing) and I think force-merging the VCF would be all fine. What I am saying is HEADER information is least of the concern for what I am doing, but all the VCF merge tools are complaining about error somewhere in HEADER. I also don't have much time to fix that bug as of right now.

I think the best option for right now, is just merge the VCF files (different samples), without any complex manipuation.

ADD REPLY
0
Entering edit mode
7.5 years ago

Bcftools has subcommands merge and annotate VCF files.

https://samtools.github.io/bcftools/bcftools.html

ADD COMMENT

Login before adding your answer.

Traffic: 1623 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6