fill in dates and use previous values
问题 my pandas dataframe looks like the below country date gd US 01-01-2014 2 US 01-01-2015 3 US 01-01-2013 0.4 UK 01-01-2000 0.7 UK 02-01-2001 0.5 UK 01-01-2016 1 what I want to do is : 1) Fill all dates (daily) starting from each countries minimum date so say for US it is 01-01-2013 upto today and for UK it is 01-01-2000 daily upto today. 2) Fill gd column with previous available data many thanks for your help 回答1: In [67]: today = pd.to_datetime(pd.datetime.now()).normalize() In [68]: l = df