How is it possible to override the constructor of the GRanges class?
0
0
Entering edit mode
@shaurya-jauhari-13552
Last seen 5.9 years ago
China

The GRanges class from Bioconductor provides for a optimized way to store sequence information and also extends the usage by accommodating further information if required, i.e. via mcols. But the restriction here is addition in terms of column-only format. What if I am looking to extend the profile of the GRanges object by including a character attribute. eg.

temp <- GRanges(seqnames= . . . , ranges = . . .)

temp$name <- "ABC"

Here I want to have a character variable (accessible from the object), name that holds some textual information. Would it be possible by overriding the constructor of GRanges or am I going too far with this.

Thanks in advance.

Best,

Shaurya.

genomicranges granges • 897 views
ADD COMMENT
0
Entering edit mode

Maybe you are looking for metadata(temp)$name <- "ABC"?

ADD REPLY

Login before adding your answer.

Traffic: 428 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