Question: How Reads Are Distributed Over My Targeted Regions
gravatar for Vikas Bansal
8.6 years ago by
Vikas Bansal2.4k
Berlin, Germany
Vikas Bansal2.4k wrote:

Hello everyone,

We have sequenced some targeted regions and mapped reads (36bp) to whole reference genome (hg18). I have a bed file which have coordinates of captured regions. I want to see (plot), what is the distribution of reads mapped to my captured regions relative to 100bp up and 100bp down to captured regions. Example - I have 10,000 regions captured but I mapped reads to whole genome. All captured regions have different length and I want to calculate relative value for all the regions so that I can make a nice plot. If I have a region, say,

chr1    153     400

Now I want to see, how many reads are mapped to 153-100 i:e from 53 to 153 and 400+100 i:e from 400 to 500 and of course from 153 to 400. So I have 3 read depth values. I want to do it for all captured regions. I can calculate this for all regions using bedtools coverageBed but in the end, I have to plot the relative values to show how reads are distributed from 100 bp upstream of captured regions, then captured regions and then 100bp downstream of captured regions.

Any suggestions? How would you do it?

Thanks and Best regards,


read plot • 2.6k views
ADD COMMENTlink written 8.6 years ago by Vikas Bansal2.4k

Do you want to generate a plot summarizing all regions, or do you want to generate one plot per region of interest?

One way to generate nice per-region graph would be to take your SAM/BAM files, convert them to wiggle files, then visualize them as a custom track in the UCSC genome browser.

ADD REPLYlink modified 8.5 years ago by Istvan Albert ♦♦ 85k • written 8.6 years ago by Eric Fournier1.4k

Thanks for your reply. I want to generate a plot summarizing all regions. I think, I have to apply some statistics to generate relative values overall.

ADD REPLYlink written 8.6 years ago by Vikas Bansal2.4k
gravatar for Jorge Amigo
8.5 years ago by
Jorge Amigo12k
Santiago de Compostela, Spain
Jorge Amigo12k wrote:

since you are interested in those 3 region sets (upstream, proper region, downstream), I would generate 2 or 3 different bed files containing such regions (2 in case you want to merge upstream and downstream regions, 3 if not), then get the coverages through bedtools' coverageBed, and summarize those numbers "manually" at the end.

ADD COMMENTlink written 8.5 years ago by Jorge Amigo12k

Thanks. I did the same thing. :)

ADD REPLYlink written 8.5 years ago by Vikas Bansal2.4k
Please log in to add an answer.


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