Unable to generate VCF using bcftools
1
0
Entering edit mode
5.3 years ago
arshiya.g02 ▴ 10
Exception in thread "main" htsjdk.tribble.TribbleException$MalformedFeatureFile: Unable to parse header with error: Input stream does not contain a BCF encoded file; BCF magic header info not found, at record 0 with position 0:, for input source: file:///home/arshiya/efs/FastQC/ERR101899_sorted.bcf
    at htsjdk.tribble.TribbleIndexedFeatureReader.readHeader(TribbleIndexedFeatureReader.java:263)
    at htsjdk.tribble.TribbleIndexedFeatureReader.<init>(TribbleIndexedFeatureReader.java:102)
    at htsjdk.tribble.TribbleIndexedFeatureReader.<init>(TribbleIndexedFeatureReader.java:127)
    at htsjdk.tribble.AbstractFeatureReader.getFeatureReader(AbstractFeatureReader.java:120)
    at htsjdk.tribble.AbstractFeatureReader.getFeatureReader(AbstractFeatureReader.java:80)
    at htsjdk.variant.vcf.VCFFileReader.<init>(VCFFileReader.java:140)
    at htsjdk.variant.vcf.VCFFileReader.<init>(VCFFileReader.java:92)
    at picard.vcf.VcfFormatConverter.doWork(VcfFormatConverter.java:97)
    at picard.cmdline.CommandLineProgram.instanceMain(CommandLineProgram.java:305)
    at picard.cmdline.PicardCommandLine.instanceMain(PicardCommandLine.java:103)
    at picard.cmdline.PicardCommandLine.main(PicardCommandLine.java:113)
Caused by: htsjdk.tribble.TribbleException: Input stream does not contain a BCF encoded file; BCF magic header info not found, at record 0 with position 0:
    at htsjdk.variant.bcf2.BCF2Codec.error(BCF2Codec.java:482)
    at htsjdk.variant.bcf2.BCF2Codec.readHeader(BCF2Codec.java:153)
    at htsjdk.variant.bcf2.BCF2Codec.readHeader(BCF2Codec.java:58)
    at htsjdk.tribble.TribbleIndexedFeatureReader.readHeader(TribbleIndexedFeatureReader.java:261)
    ... 10 more
next-gen • 1.4k views
ADD COMMENT
0
Entering edit mode

you're not using bcftools here but picard.

ADD REPLY
0
Entering edit mode

Thank you.. What is the command for converting the BAM file to BCF

ADD REPLY
0
Entering edit mode

It would be a good start to show your command lines, which is good practice when asking questions, see Brief Reminder On How To Ask A Good Question

ADD REPLY
0
Entering edit mode
5.3 years ago

your file 'ERR101899_sorted.bcf' is not a BCF file

check this with:

file ERR101899_sorted.bcf

output should be something like " Binary Call Format (BCF) version 2.1" or "compressed gzip file"

otherwise show us the output of

head ERR101899_sorted.bcf
ADD COMMENT
0
Entering edit mode

This is what I get when I use the header command

chr1    633613  A   1   ^!. 2
chr1    633614  A   1   .   3
chr1    633615  A   1   .   9
chr1    633616  A   1   .   =
chr1    633617  T   1   .   M
chr1    633618  A   1   .   [
chr1    633619  T   1   .   [
chr1    633620  T   1   .   g
chr1    633621  A   1   .   ]
chr1    633622  A   1   .   g
ADD REPLY
0
Entering edit mode

it looks like the output of samtools mpileup. There is something wrong in your worklow.

ADD REPLY

Login before adding your answer.

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