SEQanswers

Go Back   SEQanswers > Bioinformatics > Bioinformatics



Similar Threads
Thread Thread Starter Forum Replies Last Post
CLC- extracting sequences based on coverage/length gevielr Bioinformatics 2 07-15-2015 12:25 PM
Extracting features above a certain coverage annavilborg Bioinformatics 5 06-26-2013 05:23 PM
extracting conservation scores for large sets of genomic regions dphansti Bioinformatics 0 01-11-2013 05:19 PM
Extracting specific regions from binary .map file mhayes Bioinformatics 0 08-15-2011 12:14 PM
Extracting base coverage and quality values from BAM files unagaswamy Bioinformatics 9 11-11-2010 06:55 AM

Reply
 
Thread Tools
Old 01-20-2015, 07:44 AM   #1
drea11
Junior Member
 
Location: Canada

Join Date: Aug 2014
Posts: 9
Default Extracting Regions of Zero Coverage

I am looking for a quick and simple way to identify regions of zero coverage in a sequencing set. My ultimate goal is to try and determine whether there might be genomic features which contribute to this.

I've used both GATK and Samtools depth to identify the depth of coverage at each base position across my genome. What I'd like is to have the base positions for each REGION which are not covered (ie. 2307-2412). I have depth of coverage on many samples, and would like to have a quick way of getting this information across all of them. Are there any functions out there which could do this? Am I better off just sticking with some sort of bash command?

Below is a sample of what the output of GATK is (depthofcoverage) as an example.

Locus Total_Depth Average_Depth_sample Depth_for_s1 Depth_for_s2 Depth_for_s3
genome:1 283 94.33 82 111 90
genome:2 284 94.67 82 111 91
genome:3 285 95.00 82 112 91
drea11 is offline   Reply With Quote
Old 01-20-2015, 07:57 AM   #2
dpryan
Devon Ryan
 
Location: Freiburg, Germany

Join Date: Jul 2011
Posts: 3,480
Default

I imagine that tabix indexing/fetching would be useful here. That's the basis for things like indexing VCF files.
dpryan is offline   Reply With Quote
Old 01-20-2015, 10:05 AM   #3
drea11
Junior Member
 
Location: Canada

Join Date: Aug 2014
Posts: 9
Default

Thanks for the speedy reply. Could you perhaps elaborate on your answer a bit? I'm not familiar with tabix, and the online documentation seems somewhat unspecific.
drea11 is offline   Reply With Quote
Old 01-20-2015, 10:27 AM   #4
piet
Member
 
Location: planet earth

Join Date: Aug 2014
Posts: 21
Default

Quote:
Originally Posted by drea11 View Post
I'd like is to have the base positions for each REGION which are not covered (ie. 2307-2412)
Maybe the 'genomecov' subcommand from 'bedtools' with option '-bga' is useful for you.

http://bedtools.readthedocs.org/en/l...genomecov.html
piet is offline   Reply With Quote
Old 01-20-2015, 11:40 AM   #5
dpryan
Devon Ryan
 
Location: Freiburg, Germany

Join Date: Jul 2011
Posts: 3,480
Default

Quote:
Originally Posted by drea11 View Post
Thanks for the speedy reply. Could you perhaps elaborate on your answer a bit? I'm not familiar with tabix, and the online documentation seems somewhat unspecific.
If we modify your file slightly so that the contig and position are in different columns and replace spaces with tabs:
Code:
Locus	Pos	Total_Depth	Average_Depth_sample	Depth_for_s1	Depth_for_s2	Depth_for_s3
genome	1	283	94.33	82	111	90
genome	2	284	94.67	82	111	91
genome	3	285	95.00	82	112	91
Then we can:
Code:
bgzip foo.tab
tabix -b 2 -e 2 -f -s 1 -S 1 foo.tab.gz #This will index the file
tabix foo.tab.gz genome:2-3
The last command will output the last 2 lines. Of course if you have a LOT of lines and multiple contigs/chromosomes/genomes, then this is more useful than the small example. The biggest benefit to this method is that you can randomly ask for ranges without needing to process everyline until you get to that range (if you've ever dealt with indexed VCF or BAM files, it's the same underlying principle). This is actually how IGV and many other tools randomly access VCF and BED files.

Note that the bgzip utility is really just a special version of gzip, so you can view the resulting files with zcat or even just gunzip them.
dpryan is offline   Reply With Quote
Reply

Tags
analysis, sequencing, sequencing depth

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 04:11 PM.


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