[BioC] Getting Introns Expression at a Per Gene Level
Valerie Obenchain
vobencha at fhcrc.org
Tue Sep 10 18:31:15 CEST 2013
Hi Carl,
You can use import() from rtracklayer to read a bed in as a GRanges.
gr <- import('myfile.bed', asRangedData=FALSE)
I'm not sure what you've got in your file but let's say they are gene
isoforms. Presumably there is an identifier in the file that would let
you group the ranges by gene (or whatever grouping you are after). This
will likely end up as one of the metadata columns in the GRanges after
import. Create a GRangesList by grouping the GRanges by gene.
grl <- split(gr, bySomeFactor)
The introns are the gaps between the ranges in each list element of the
GRangesList. To get at these we want the difference between the full
range of the gene and the multiple elements (exons or transcripts etc.)
of the gene.
Create the gene ranges:
geneRanges <- range(grl)
Extract the differences:
introns <- psetdiff(geneRanges, grl)
If this doesn't help, I'll need to know more detail about the data in
the isoform file.
Valerie
On 09/09/2013 07:31 PM, Carl Baribault wrote:
> Dear Valerie,
> I have a bed file of specific isoforms of interest. Can you please suggest
> a best approach for obtaining the intron extents? Thanks.
>
> Best,
> Carl Baribault
>
> [[alternative HTML version deleted]]
>
> _______________________________________________
> Bioconductor mailing list
> Bioconductor at r-project.org
> https://stat.ethz.ch/mailman/listinfo/bioconductor
> Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor
>
More information about the Bioconductor
mailing list