Mar-18-2019, 02:55 PM
date_cols = ['CLOSE', 'D_MONTH', 'OPEN'] gbl = globals() for i in date_cols: gbl[i] = pd.to_timedelta(min(data_frame_1[i]), unit='s') + pd.datetime(1960, 1, 1)I am getting the output as below
Output:>OPEN
Out[520]: Timestamp('1993-02-12 00:00:00')
>CLOSE
Out[522]: Timestamp('2009-04-30 00:00:00')
>D_MONTH
Out[523]: Timestamp('2018-01-01 00:00:00')
But I want the output like below as a dataframe not as a timestamp:Output:Attr Min_Date
CLOSE 2009-04-30 00:00:00
OPEN 1993-02-12 00:00:00
D_MONTH 2018-01-01 00:00:00