Created
November 18, 2014 01:46
-
-
Save earino/022b9e4273d465c70354 to your computer and use it in GitHub Desktop.
tbl_df drops?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
> tbl_df(iris) %>% class() | |
[1] "tbl_df" "tbl" "data.frame" | |
> tbl_df(iris) %>% filter(Species == "setosa") %>% class() | |
[1] "tbl_df" "tbl" "data.frame" | |
> tbl_df(iris) %>% filter(Species == "setosa") %>% .[,"Species"] %>% class() | |
[1] "factor" | |
> tbl_df(iris) %>% filter(Species == "setosa") %>% .[,"Species"] %>% str() | |
Factor w/ 3 levels "setosa","versicolor",..: 1 1 1 1 1 1 1 1 1 1 ... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I don't get the same results as you in the last two cases, which makes me think you should update
dplyr
. In my hands, even the last two statements return something of classtbl_df
anddata.frame
.