You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In conjunction with using dplyr on a data.table, this still happens. Presumably the error can also occur when other classes remove data.table from being the pole position class.
Here's a reproducible Rmd file:
`:=` prints in conjunction with dplyr, because dplyr adds all kind of classes to data.tables
```{r}
library(dplyr); library(data.table)
mtcars = data.table(mtcars)
grouped = mtcars %>% group_by(cyl)
grouped[, mpg := 2]
class(grouped)
class(grouped) = c("data.table", "grouped_dt", "tbl_dt", "tbl", "data.frame") // reorder classes
grouped[, mpg := 2]
grouped = mtcars %>% group_by(cyl) %>% data.table()
grouped[, mpg := 2]
class(grouped)
```
This is with data.table_1.9.5, dplyr_0.4.1 and knitr_1.9.
Submitted by: Matt Dowle; Assigned to: Nobody; R-Forge link
As raised on SO here
The text was updated successfully, but these errors were encountered: