Thursday, June 11, 2020

How to read excel sheets from file using python

1. The below transaction file has multple sheets in it. Now we are trying to read the Expense sheet name using python padas.

Syntax:

Readsheet= pd.read_excel(r'G:\DatascienceProjects\examples_datasets\transactions.xlsx', sheet_name = 'Expense') # Name of sheet to read from
#pd.read_excel()
Readsheet.head(3) 

No comments:

Post a Comment

Element wise operation on LIST vs ARRAY

The use of arrays over lists: You can write  vectorised  code on numpy arrays, not on lists, which is  convenient to read and write, and con...