I imported a CSV file containing dates from a SQL query, however the dates are actually date-time values, which R does not recognise:
> mydate
1/15/2006 0:00:00 0:00:00 0:00:00 0:00:00 0:00:00 0:00:00
Levels: 2373 0:00:00 1/1/2006 0:00:00 0:00:00 1/1/2007 0:00:00 0:00:00 1/1/2008 0:00:00... 0:00:00 on September 9, 2012
> the class (mydate)
"Factor" is the first word that comes to mind.
as.Date > (mydate)
charToDate(x) has an error:
The character string is not in an unambiguous standard format.
What is the best way to convert mydate to date format? (It's not necessary for me to mention the time component.)