How to get the consensus sequence region from a BAM alignment, with ref genome coordinates
0
0
Entering edit mode
7.8 years ago
valopes ▴ 30

I am trying to get the consensus sequence region from a .bam file.

I've tried:

samtools mpileup -C50 -gf ref.fa -r Chr13:1,000-2,000 aln.bam

and I got

[bam_parse_region] fail to determine the sequence name.

[mpileup] malformatted region or wrong seqname for US-18.bam

Please, waht am I doing wrong? I really need to figure out but I have no experience with it

Tks.

sequence • 3.1k views
ADD COMMENT
0
Entering edit mode

Hi @valopes, I think I helped you with this question yesterday - C: Get part of a sequence from a .bam file, considering the reference genome positi , I am not sure what is your region of interest from the genome but clearly you did not read or understand the manual properly. -r parameter is used to specify the region of interest in the reference genome.

ADD REPLY
0
Entering edit mode

Yes, I know that you answer me yesterday. Thank you. However, It looks like my problem now is to determine the sequence name.

The reference genome is Gm13 and .bam file Chr:13, do you think that this is the problem?

Thanks

ADD REPLY
0
Entering edit mode

Yes, that should be the fasta header of the chromosome of interest followed by a : and the coordinates separated by -

ADD REPLY

Login before adding your answer.

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