Python Pandas Read Excel File Multiple Sheets Example
In this article, we will cover python pandas read excel multiple sheets. I explained simply step by step python read excel file with multiple sheets pandas. This example will help you how to read multiple sheets in excel using python pandas. This article goes in detailed on python pandas read xlsx multiple sheets. Follow the below tutorial step of read excel file with multiple sheets in python pandas.
In this example, we will read excel file with multiple sheets using python pandas library. we will use read_excel() and get() functions to read excel file with multiple sheets using python pandas. so let's see a simple example.
You can use these examples with python3 (Python 3) version.
I simply created data.xlsx file with SheetOne and SheetTwo as like below, we will use same file for both example:
# import pandas lib as pd import pandas as pd # Read Demo file with SheetOne and SheetTwo dataFrame = pd.read_excel('demo.xlsx', ['SheetOne', 'SheetTwo']) sheetOne = dataFrame.get('SheetOne') sheetTwo = dataFrame.get('SheetTwo') print(sheetOne) print(sheetTwo)
ID Name Email 0 1 Hardik Savani firstname.lastname@example.org 1 2 Vimal Kashiyani email@example.com 2 3 Harshad Pathak firstname.lastname@example.org ID Name 0 1 Hardik 1 2 Vimal 2 3 Harshad
I hope it can help you...
We are Recommending you
- Python Xlsxwriter Create Excel File with Multiple Sheets
- Python Xlsxwriter Create Excel File Example
- Python Openpyxl Create Excel File with Multiple Sheets
- Python Openpyxl Create Excel File Example
- Python Pandas Create Excel File with Multiple Sheets
- Python Pandas Create Excel File Example
- How to Create and Write Xlsx File in Python?
- How to Create Excel File in Python?
- Python Read Excel File using Pandas Example
- How to Open and Read Xlsx File in Python?
- How to Read Excel File in Python?
- Python Write CSV File from List Example
- Python Create Text File If Not Exists Example
- Python Create Zip Archive from Directory Example