Hi Kevin,

Thanks for the report. The old behavior of as.data.frame on 'RangedData' objects has been re-instated in IRanges 1.99.7.

Last week we added a new as.data.frame,List method that is now used by all 'List' objects. This was done for a variety of reasons that I'll include in an announcement on the mailing list. The long and the short of it is that 2 new columns have been added, 'group' and 'group_name' and you'll have the ability to keep outer metadata set on the 'List' object.

I did not intend to change the behavior of as.data.frame,RangedData. What happened was the method calls a couple of as.data.frame() methods on 'List' objects. Once I removed the old 'List' methods, as.data.frame,RangedData went through the new 'List' methods which created the new columns you were seeing.

Eventually RangedData objects will be phased out so we've decided to keep the legacy behavior instead of updating them to include the new columns.

Sorry for the inconvenience.

Valerie


On 04/28/2014 01:02 PM, Kevin Ushey wrote:
Hi,

With the following code and IRanges 1.99.6:

   ranges <- IRanges(c(1,2,3),c(4,5,6))
   rd <- RangedData(ranges)
   as.data.frame(rd)

I get

as.data.frame(rd)
   group group_name start end width group_name.1
1     1          1     1   4     4            1
2     1          1     2   5     4            1
3     1          1     3   6     4            1

With the current release version (IRanges 1.22.4), I get

as.data.frame(rd)
   space start end width
1     1     1   4     4
2     1     2   5     4
3     1     3   6     4

This seems like a bug.

Thanks,
Kevin

sessionInfo()

R Under development (unstable) (2014-04-05 r65382)
Platform: x86_64-apple-darwin13.1.0 (64-bit)

locale:
[1] en_CA.UTF-8/en_CA.UTF-8/en_CA.UTF-8/C/en_CA.UTF-8/en_CA.UTF-8

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base

_______________________________________________
Bioc-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/bioc-devel


_______________________________________________
Bioc-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/bioc-devel

Reply via email to