Skip to content Skip to sidebar Skip to footer

How Do I Edit Xlsx Spreadsheets With Pandas

How do I edit spreadsheets using pandas, or any other library. I have a CSV where I do the data reading and some filters, which I intend to save in an XLSX worksheet ready. But whe

Solution 1:

In pandas version 0.24 they will be an option for mode='a'; however; right now you will have to:

writer = pd.ExcelWriter(excel_name, engine='openpyxl')
writer.book = load_workbook(excel_name)
df5.to_excel(writer, sheet_name='FullExport', index=False)
writer.save()
write.close() # i think close() already runs the save function above

Post a Comment for "How Do I Edit Xlsx Spreadsheets With Pandas"