📜  基于列合并三个数据框 pandas - Python 代码示例

📅  最后修改于: 2022-03-11 14:46:32.337000             🧑  作者: Mango

代码示例4
# Merging 3 or more dataframes base on a common column
import pandas as pd
from functools import reduce

#Create a list of df to combine
list_of_df = [df_1,df_2,df_3]

#merge them together
df_combined = reduce(lambda left,right: pd.merge(left,right,on='common column'), list_of_df)