error in dcast when non atomic columns present #29

Open
piccolbo opened this Issue Nov 26, 2012 · 3 comments

Comments

Projects
None yet
2 participants

Hi,
I have a data frame with two columns which are lists of raw vectors. When I try to run dcast on it I get this error:

Error in sort.int(x, na.last = na.last, decreasing = decreasing, ...) : 
  'x' must be atomic

no matter what formula I enter. I was wondering if there is a way to make this work. The larger context is that I am reading data from HBase. It originally comes out in melted form, with columns: key (a raw vector), family, columns (these two raw but can be converted to character) and value (again a raw vector). The first three columns uniquely identify a value. The key and value columns are serialized objects, possibly complex (say nested lists). Thanks

Antonio

Owner

hadley commented Nov 26, 2012

Could you provide a small reproducible example please?

dcast(data.frame(x=1:3, y = I(list("a",2L,3.1))), y~x)
Owner

hadley commented Dec 4, 2012

Thanks - it's unlikely I'll get to this in the near future, but I'll take a look the next time I'm working on reshape

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment