bedtools interset doesn't return a VCF file?
1
0
Entering edit mode
2.1 years ago
ManuelDB ▴ 80

I am filtering a VCF file with a bed file using Bedtools. I have carried out this successfully with

 bedtools intersect -wb -a myVCF.vcf -b myBEDfile.bed > output.txt 

However, what I want is to get a VCF file with the metadata and the header because after this, the application I am developing will require the format of a VCF file. I thought that is a very common filtering operation but reading bedtools interest documentation I can't find anything.

bedtools • 533 views
ADD COMMENT
4
Entering edit mode
2.1 years ago
Trivas ★ 1.8k

Have you used the -header flag? From the documentation:

-header | Print the header from the A file prior to results.

ADD COMMENT

Login before adding your answer.

Traffic: 1845 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