[datatable-help] dput does not work with data.table

Christoph_Jae christoph.jaeckel at wi.tum.de
Fri Mar 30 16:09:11 CEST 2012


Hi together,

while trying to write a minimal example for a problem that is bothering me,
I discoverd that dput() does not work on data.tables. More precisely, the
output of dput cannot be read in, most probably because the
".internal.selfref = <pointer: ..." syntax causes problems:

library(data.table)
DT <- data.table(A=1:2, B=2:3)
dput(DT)
structure(list(A = 1:2, B = 2:3), 
          .Names = c("A", "B"), 
          row.names = c(NA, -2L), 
          class = c("data.table", "data.frame"), 
          .internal.selfref = <pointer: 0x0000000000150788>)

Trying to read the structure part gives: "Error: unexpected '<' in:
"          class = c("data.table", "data.frame"), 
          .internal.selfref = <"

Are there any workarounds? If not, is this a base-R problem or a data.table
specific problem?

Thanks Christoph

--
View this message in context: http://r.789695.n4.nabble.com/dput-does-not-work-with-data-table-tp4519150p4519150.html
Sent from the datatable-help mailing list archive at Nabble.com.


More information about the datatable-help mailing list