Kindly help manage read .xlsx files using pandas, thank you

import numpy as np
import pandas as pd
from pandas import Series, DataFrame

excelfile = pd.ExcelFile('C:\Users\THOMAS\Documents/Hash Analytics
Internship - DemoS2.xlsx')
dframe = excelfile.parse('Sheet10')
print (dframe)


C:\Users\THOMAS\AppData\Local\Programs\Python\Python39\python.exe
"C:/Users/THOMAS/PycharmProjects/Assignment#2/code File.py"
  File "C:\Users\THOMAS\PycharmProjects\Assignment#2\code File.py", line 5
    excelfile = pd.ExcelFile('C:\Users\THOMAS\Documents/Hash Analytics
Internship - DemoS2.xlsx')

                    ^
SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes in
position 2-3: truncated \UXXXXXXXX escape

Process finished with exit code 1
-- 
Best Regards,

*A. M. Thomas*
Electrical & Solar Systems Expert
*THE GUY BEHIND THE SCENE*
Cell: +254 723 309 157 / +254 731 406 125
Email: thomaso...@gmail.com / thomaso.engin...@gmail.com

"Alternative energy for real and sustainable development that we need"
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to