Hello everyone.
Another day, another question.
What Am I doing wrong here?
I want to transform the variable from "Apr 2016" to "01-04-2016"
I have no idea why isnt working.
dat <- data.frame(
dates = c("Apr 2016","Apr 2017","Apr 2018","Apr 2019")
)
dat$dates <- paste0("1 ", dat$dates)
dat$dates <- as.Date(x = dat$dates , format = "%d%b%Y")
Thank you in advance