I have imported a csv file into r and there is a column which I want to format to date.
The data is as this: "01.01.2018 00:00" in the columns.
I have tried the as.date function but this results in NA's
I have tried converting the column to numeric first but then the data is converted to NA's
I have tried a number of ways to get the data formatted but none worked.
I have df$col <- as.POSIXct("21.01.2018 00:00", format = "%d-%m-%y %H:%M")
I keep getting the above error,
character string is not in a standard unambiguous format.
I have read lots on this and I cannot get a resolution so would really appreciate some guidance.