This is a test version of Biostars. For the public version, visit https://www.biostars.org.
intersection of vcf files with bcf isec - no header

Hi everyone,

I'm trying to use bcftools isec to identify the variants found in all 8 vcf files. This is the code I'm running below:

bcftools isec -n +8 file1.vcf.gz file2.vcf.gz file3.vcf.gz file4.vcf.gz file5.vcf.gz file6.vcf.gz file7.vcf.gz file8.vcf.gz > output.vcf

This is generating a vcf file with a list of variants, but there is no header to the file, which means I'm struggling to do any further analysis on it or open it in IGV etc. I've tried copying a header from the first file onto this, but I get this error 'Broken VCF record, the number of columns at Chr1:90313 does not match the number of samples (0 vs 1)', I don't know if this is related to sticking on a header from a different vcf.

Does anyone have any advice on this?

isec bcftools vcf

In the directory where you ran this there should be a README.txt file. Check that.

I don't seem to have this file in the directory, I ran this on an HPC and it didn't seem to generate any .txt file and there's nothing in the .out file either

0 answers

No answers yet.

Log in to answer this question.