error in query a BAM file
1
0
Entering edit mode
7.0 years ago
shoujun.gu ▴ 380

I'm the beginner of using samtools. I downloaded: efetch -db=nuccore -format=gb -id=AF086833 > AF086833.gb

and then try to query a bam file: samtools view -c bwa.bam AF086833:470-2689

it showed: [main_samview] region "AF086833:470-2689" specifies an unknown reference name. Continue anyway.

Any suggestions why this error occur? Thanks in advance.

software error samtools • 1.1k views
ADD COMMENT
0
Entering edit mode
7.0 years ago

what's the point of fetching a genbank file ?

efetch -db=nuccore -format=gb -id=AF086833 > AF086833.gb

there is no contig named AF086833 the bam file. That's why you get an error with

samtools view -c bwa.bam AF086833:470-2689

to see the contigs in the bam use

 samtools view -H bwa.bam | grep "@SQ"
ADD COMMENT

Login before adding your answer.

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