I have a recently made data.frame that has three columns, Date, Time, and Data. I'm looking to combine the date and the time variables into one Date.Time variable.
My data.frame is called, data_dataframe and looks like this:
Date Time Data
1/26/94 13:00 8.4
I tried:
as.POSIXct(paste(data_dataframe$Date, data_dataframe$Time), format="%d/%m/%Y %H:%M:%S")
but this didn't work. Reading around didn't seem to help my problem. Any tips?
解决方案
you could try this which will create a new column with 'New_DateTime'
data_dataframe$New_DateTime