Skip to content
Prev 17917 / 21312 Next

[Bioc-devel] non-subsettable GRanges object

Hi Oleksii,

It looks like we have a long-standing bug in the rbind() method for 
DataFrame objects that is somehow surfacing now. Here is a simple example:

   library(IRanges)
   DF1 <- DataFrame(A=I(list(11:12, 21:23)))
   DF2 <- DataFrame(A=IntegerList(31:34, 41:45, 51:56))
   DF3 <- rbind(DF1, DF2)
   DF3
   # DataFrame with 3 rows and 1 column
   #                                        A
   #                                   <list>
   # 1                                  11,12
   # 2                               21,22,23
   # 3 31,32,33,...,41,42,43,...,51,52,53,...

This result is wrong. We observe this in release and devel.

If you look at the mcols of the GRanges object returned by getAMR() in 
your code below, you'll see that it's actually an invalid DataFrame 
object (its first column has 23 elements but 22 are expected). This is a 
consequence of the above bug. Even though the bug has existed for a long 
time, somehow it was not affecting your code. However this changed 
recently because of some minor refactoring of the rbind() method for 
DataFrame objects that I made a few days ago in S4Vectors.

I'm working on a fix and will let you know when it's ready.

Cheers,
H.
On 4/5/21 1:12 PM, Oleksii Nikolaienko wrote: