📜  合并多个 csv 文件 - Python 代码示例

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

代码示例1
path = r'C:\DRO\DCL_rawdata_files' # use your path
all_files = glob.glob(path + "/*.csv")

li = []

for filename in all_files:
    df = pd.read_csv(filename, index_col=None, header=0)
    li.append(df)

frame = pd.concat(li, axis=0, ignore_index=True)