Question: coordinate of BAM and BED
0
gravatar for yuabrahamliu
10 months ago by
yuabrahamliu30
yuabrahamliu30 wrote:

Hi all, I want to use bedtools multicov to count the RNAseq reads in specific bed file intervals (containing all the intron intervals of mm10 genome downloaded from UCSC). However, I noted that the BED file coordinate is 0-based, while the BAM file used by bedtools multicov was sorted by samtools and its coordinate was 1-based. So, do I need to transform the coordinate of the BAM file from 1-based to 0-based before run the bedtools multicov command? Thank you.

rna-seq alignment genome • 485 views
ADD COMMENTlink modified 10 months ago by Devon Ryan84k • written 10 months ago by yuabrahamliu30
1
gravatar for Devon Ryan
10 months ago by
Devon Ryan84k
Freiburg, Germany
Devon Ryan84k wrote:

BAM files are never 1-based, they are always 0-based and samtools will never change this. What you've likely noticed is that the SAM file you see with samtools view is 1-based, since SAM uses 1-based coordinates. Regardless, bedtools is aware of the coordinates used in its supported file types and handles that properly internally.

ADD COMMENTlink written 10 months ago by Devon Ryan84k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 625 users visited in the last hour