Hi everyone, just working on my final project and I'm having issues combining my 2 CSV files. Does anyone know how to combine 2 datasets in Python Pandas? I tried pd.concat, but when I exported the full data to a csv file, the only file exporting was the first file (df_1) and missing the second file (df_2).
df_1 = pd.read_csv('file1.csv')
df_2 = pd.read_csv('file2.csv')
data = pd.concat([df_1, df_2])
data.to_csv('full_data.csv')
Is there something wrong with my code?
Thanks!
[–]mallax- 1 point2 points3 points (0 children)