Question: Computing coverage from BAM file?
0
gravatar for maryamom99
3.3 years ago by
maryamom990
maryamom990 wrote:

Hi every one!

I want to compute depth of specific regions from BAM file.I found two solutions like bellow :

samtools depth -r  <region>  my.bam     

and 

samtools view my.bam <region>

that give me two different answers,I was wondering what is exactly the applications of theses two command and which one is more correct answer to computing depth of region?

Thanks a lot!

bam depth covrage • 1.3k views
ADD COMMENTlink modified 3.3 years ago by Jennifer Hillman Jackson25k • written 3.3 years ago by maryamom990
0
gravatar for Jennifer Hillman Jackson
3.3 years ago by
United States
Jennifer Hillman Jackson25k wrote:

Hello,

http://www.htslib.org/doc/samtools.html

"view" will report all data within a particular region
"depth" is the how many reads at the particular position

You might find the tool BEDTools -> Create a BedGraph of genome coverage a useful alternative.

Best, Jen, Galaxy team

 

ADD COMMENTlink written 3.3 years ago by Jennifer Hillman Jackson25k

Thanks Jennifer!

ADD REPLYlink written 3.3 years ago by maryamom990
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 16.09
Traffic: 186 users visited in the last hour