-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Closed
Description
I'm not entirely sure what's going on here but slice() appears to shuffle the order of class and tzone attributes of datetime columns:
library(dplyr)
df <- data.frame(datetime = lubridate::now(tzone = "UTC"))
attributes(df$datetime)
#> $class
#> [1] "POSIXct" "POSIXt"
#>
#> $tzone
#> [1] "UTC"
attributes(slice(df, n())$datetime)
#> $tzone
#> [1] "UTC"
#>
#> $class
#> [1] "POSIXct" "POSIXt"This seems specific to dplyr functions that touch rows: so select() and mutate() doesn't do this but filter() and arrange() does.
Metadata
Metadata
Assignees
Labels
No labels