coverage on exons with bedtools genomecov
1
1
Entering edit mode
8.0 years ago
guillaume.rbt ★ 1.0k

Hello everyone,

I would like to have per-base coverage of a bam file of an RNAseq experiment, but only on exons.

I know how to do that on all genome with bedtools:

bedtools genomecov -d -ibam aligned_reads.bam -g genome.fa > cov.txt

And I have a gff file giving me the position of exons on my species.

Does anyone know a way to have the same result, but only on given exon positions?

Thanks,

Guillaume

bedtools RNA-Seq exons coverage • 2.8k views
ADD COMMENT
2
Entering edit mode
8.0 years ago
Jeffin Rockey ★ 1.3k

From the gff extract those lines of exons only. something like below

awk<file.gff -F'\t' '$3==“exon”{print}' >exons.gff

Now use bedtools coverage with the above gff and your bam file with -d and other options that suits your purpose

ADD COMMENT
0
Entering edit mode

Thank for the tip. Works fine :)

ADD REPLY

Login before adding your answer.

Traffic: 2045 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6