Python Forum
Compare two Excel sheets with Python and list diffenrences
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Compare two Excel sheets with Python and list diffenrences
#2
you can use pandas, see: https://stackoverflow.com/a/37113788

The code provided on post above:
import pandas as pd

df1 = pd.read_excel('excel1.xlsx')
df2 = pd.read_excel('excel2.xlsx')

difference = df1[df1!=df2]
print difference
Reply


Messages In This Thread
RE: Compare two Excel sheets with Python and list diffenrences - by Larz60+ - Oct-09-2021, 03:30 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Search Excel File with a list of values huzzug 4 1,215 Nov-03-2023, 05:35 PM
Last Post: huzzug
  trouble reading string/module from excel as a list popular_dog 0 416 Oct-04-2023, 01:07 PM
Last Post: popular_dog
Lightbulb Help using Google Sheets matheuspimenta 0 715 Dec-15-2022, 05:36 PM
Last Post: matheuspimenta
Thumbs Up Need to compare the Excel file name with a directory text file. veeran1991 1 1,110 Dec-15-2022, 04:32 PM
Last Post: Larz60+
  How to loop through all excel files and sheets in folder jadelola 1 4,453 Dec-01-2022, 06:12 PM
Last Post: deanhystad
  list from excel devilonline 4 1,355 Jun-22-2022, 11:00 PM
Last Post: devilonline
Question How to make a 3D List of Excel Spreadsheets? chatguy 4 2,737 Jan-24-2021, 05:24 AM
Last Post: buran
  Compare response and name list in experiment knoxvillerailgrind 3 2,207 Jul-26-2020, 12:23 PM
Last Post: deanhystad
  identical cells in 2 different excel sheets python pandas esso 0 1,628 Jul-19-2020, 07:50 PM
Last Post: esso
  Convert Excel to complex list and2handles 1 2,032 Jun-23-2020, 01:51 PM
Last Post: DPaul

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020