Converting data in time series

Hi everybody!
I have problem of converting my excel data in time series with RStudio 4.3.1
When I import data from excel, RStudio have the option of categorizing the variable. If I convert in Date, the program change the format from yearly data to daily data.
If I use as.Date function for the file "GDP1" and time variable into the data "Time" by the script : GDP1$Time<- as.Date(GDP1$Time)
the program give the message
Error in charToDate(x) :
character string is not in a standard unambiguous format
How can I deal with it?

Look at

?as.Date

and give a format or tryformat argument that makes clear how the dates are written.

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.