SEQanswers

Go Back   SEQanswers > Bioinformatics > Bioinformatics



Similar Threads
Thread Thread Starter Forum Replies Last Post
Difference between bait and target region Brambo Bioinformatics 1 10-08-2015 07:56 AM
can we know target region of exome without bed file ? cjo4m4fm Bioinformatics 3 10-01-2013 11:19 AM
AmpliSeq custom panel, target region sizes lethalfang Ion Torrent 6 04-23-2013 10:00 AM
Targeted sequencing: Size of target region hazelperry General 1 03-27-2013 06:26 AM

Reply
 
Thread Tools
Old 07-19-2015, 06:54 AM   #1
shmibble
Member
 
Location: Israel

Join Date: May 2015
Posts: 23
Default Target region coverage

Hi,
I am performing an alignment and am interested in several target regions. I am interested in finding out the minimum and maximum coverage in each region (meaning the base with the minimum coverage and the base with the maximum coverage in each region) for quality control purposes. I already have a sorted bam file.
Does anyone know how I can do this? Is there a program that can help?

Thanks!
shmibble is offline   Reply With Quote
Old 07-21-2015, 07:23 AM   #2
amitm
Member
 
Location: Manchester, UK

Join Date: Feb 2011
Posts: 52
Default

hi,
Using bedtools coverageBed with the -hist option would give you base level coverage. (contiguous bases with same depth would be collapsed in one entry though)
http://bedtools.readthedocs.org/en/l.../coverage.html
amitm is offline   Reply With Quote
Old 07-23-2015, 01:28 AM   #3
shmibble
Member
 
Location: Israel

Join Date: May 2015
Posts: 23
Default

Thanks for the reply.
I don't really understand what I need file B for. How do I get a histogram of the coverage of file A (a sorted bam file)?

Thanks again.
shmibble is offline   Reply With Quote
Old 07-23-2015, 02:15 AM   #4
amitm
Member
 
Location: Manchester, UK

Join Date: Feb 2011
Posts: 52
Default

hi,
You would need two things -
1) Post-alignment, coord. sorted BAM
2) BED file of your target regions

Then for each of your target region (or sub-parts of it if there are different depth areas in a given target) you would get the number of reads (which is depth or coverage) aligned.

A BED file at its simples is a tab-delimited 3 col. file having Chr. Start & End coords
amitm is offline   Reply With Quote
Old 08-04-2015, 12:44 AM   #5
shmibble
Member
 
Location: Israel

Join Date: May 2015
Posts: 23
Default

Hi,

Thanks for the reply and sorry it took me a while to respond.
It still doesn't seem to work for me... Here's the command I type:

bedtools coverage -abam -a aligned_sorted.bam -b ref.bed

It says ERROR: Unrecognized Parameter: aligned_sorted.bam

If I remove the -abam option I get a different error: "Unexpected file format. Please use tab-delimited BED, GFF or VCf. Perhaps you have non-integer starts or ends at line 1?"
I'm not really sure what this means. My bed file is a 3 column tab delimited file. Each line looks like "chr10 123456789 234567891".

Any advice?

Thanks again
shmibble is offline   Reply With Quote
Old 08-04-2015, 12:53 AM   #6
amitm
Member
 
Location: Manchester, UK

Join Date: Feb 2011
Posts: 52
Default

hi,
Quickly -
The -abam and -a parameter are mutually xclusive. Use one.
If you have two BED files, say, and you want to calculate coverage of one over other. Then its like
-a First.bed -b Second.bed

Else if you have a BAM file and a BED file, then
-abam Input.bam -b Sorted.bed

Hope that clears it.

My first guess for the 2nd error is that that the chromosome name format in your BAM and BED don't match.
Check using
samtools view -H Input.bam
amitm is offline   Reply With Quote
Reply

Tags
coverage, quality control, target regions

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off




All times are GMT -8. The time now is 06:10 AM.


Powered by vBulletin® Version 3.8.9
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Single Sign On provided by vBSSO