面向表格用户的 pandas 连接
John Miller
Principal Data Scientist

pd.merge_ordered(cleveland, dallas, on='Game_Date',
suffixes=['_CLE', '_DAL'])

pd.merge_ordered(cleveland, dallas, on='Game_Date',
suffixes=['_CLE', '_DAL'])

pd.merge_ordered(tc2, td2, on='Game_Date',
suffixes=['_CLE', '_DAL'], fill_method='ffill')

pd.merge_ordered(tc2, td2, on='Game_Date',
suffixes=['_CLE', '_DAL'], fill_method='ffill')
pd.merge_asof(left_df, right_df,
direction='backward')
方向
"backward":最近且更早的日期
"forward":最近且相同或更晚的日期
"nearest":不考虑方向的最近日期

pd.merge_asof(temps, impacts,
left_on='Game_Date', right_index=True, direction='backward')
面向表格用户的 pandas 连接