[BioC] get table with aanotaed genome features

Joern Toedling Joern.Toedling at curie.fr
Tue Jun 29 11:00:41 CEST 2010


Hi Andreia,

please have a look at section 2.8 of the girafe vignette. 

The resulting object from interval_overlap(A,B) is a list of the same length
as A with the i-th list element being the indices of B that overlap A[i].

Generating a character vector of overlapping RNA types can be done with
'sapply'. Assuming your annotation object is called 'B' and contains a vector
'type' specifying the type of RNA, and the overlap list is called 'Ov', the
syntax would be something like this:
ovTypes <- sapply( Ov, function(x) paste(B$type[x], collapse=","))

This vector 'ovTypes' is of the same length as the AlignedGenomeIntervals
object, say 'A', and for exporting a table, you could use the function
'write.table':
write.table(cbind(detail(A), type=ovTypes), ... < other arguments> ...)

HTH,
Joern

On Mon, 28 Jun 2010 17:45:02 +0100, Andreia Fonseca wrote 
> Dear all, 
> 
> I have been using package girafe to annotate my set of sequences. I have
produced an object which is the overlap between my alignment file and the
annotation information, but I am struggeling > in how to export the table
which contains per each row of the alignment information which type of RNA
molecules it is. Can someone help? 
> With kind regards, 
> Andreia  
> -- 
> -------------------------------------------- 
> Andreia J. Amaral, PhD 
> Unidade de Imunologia Clínica 
> Instituto de Medicina Molecular 
> Universidade de Lisboa 
> email: andreiaamaral at fm.ul.pt 
>          andreia.fonseca at gmail.com

--- 
 Joern Toedling 
 Institut Curie -- U900 
 26 rue d'Ulm, 75005 Paris, FRANCE 
 Tel. +33 (0)156246927



More information about the Bioconductor mailing list