This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Where can I download a BED file with exonic regions?

Hello,

I'm going to perform adaptive sampling with ONT for enrichment of exonic regions. I've tried using UCSC's Table Browser with Group Genes and Gene Predictions and Track NCBI RefSeq and GENCODEV47, I've also tried using filters but I'm not sure how they work. From all the bed files I generated the percentage of covered genome is between 45 and 60% with is obviously not what I want. I've also taken into account that regions may overlap.

How can I download only the exomes?

Thank you.

exome bed

From all the bed files I generated the percentage of covered genome is between 45 and 60% with is obviously not what I want.

how did you do that ? You must use bedtools merge to merge the exons from the transcripts of the same gene.

1 answer

You can download the GTF file, for example from GENCODE, filter for type == "exon", collapse overlapping intervals and then use these coordinates as the exome.

For example:

gzip -cd gencode.v47.annotation.gtf.gz \
| awk '$1 !~ /^#/ && $3 == "exon" {print $1, $4, $5}' OFS='\t' \
| sort -k1,1 -k2,2n -k3,3n \
| bedtools merge -i - > exome.bed

That worked, thank you very much

Don't forget to follow up on your threads. If an answer was helpful, you should upvote it; if the answer resolved your question, you should mark it as accepted. You can accept more than one answer if they all work. If an answer was not really helpful or did not work, provide detailed feedback so others know not to use that answer.

Upvote|Bookmark|Accept

Log in to answer this question.