[R] Time intervals is converted into seconds after converting list of dfs into a single Df.

Allaisone 1 A||@|@one1 @end|ng |rom hotm@||@com
Tue Dec 24 17:50:05 CET 2019


Hi dear group ,

I have list of datframes with similar column names. I want to rebind all dataframes so I have a single dataframe. One of the column's in each df is of 'interval' time class which was generated from 'lubridate' package.

The problem is that when I convert the list of dfs into a single df using any of the below codes :

Library(plyr)
MySingleDf <- ldply(MyListOfDfs, data.frame)
Or
MySingleDf <- ldply(MyListOfDfs, rbind)
Or
MySingleDf <- rebind. fill (MyListOfDfs)

What heppens is that  time intervals which looks like : 2010-4-5 UTC--2011-7-9 UTC is converted into a single numeric value which seems to be the difference between the 2 dates in seconds.

When I use :
MySingleDf <- do.call ("rbind",MyListOfDfs)

The code is freezes and it shows like of the data are being analysed but no result. I have used this code previously for the same purpose but with another datse and it works perfectly.

What I want to see is that time intervals are shown as they are but not converted into seconds.

Could you please suggest any alternative syntax or modifications to my codes ?

Thank you so much in advance

Regards



	[[alternative HTML version deleted]]



More information about the R-help mailing list