Restores dates that were converted by Andromeda to numeric values back to dates.
restoreDate(x)
A numeric vector representing dates.
A vector of type Date
.
myData <- data.frame(startDate = as.Date(c("2000-01-01", "2001-01-31", "2004-12-31")))
andr <- andromeda(myData = myData)
andr$myData %>%
collect() %>%
mutate(startDate = restoreDate(startDate))
#> Warning: There was 1 warning in `mutate()`.
#> ℹ In argument: `startDate = restoreDate(startDate)`.
#> Caused by warning:
#> ! Input to restoreDate is already a Date.
#> # A tibble: 3 × 1
#> startDate
#> <date>
#> 1 2000-01-01
#> 2 2001-01-31
#> 3 2004-12-31
# # A tibble: 3 x 1
# startDate
# <date>
# 1 2000-01-01
# 2 2001-01-31
# 3 2004-12-31
close(andr)