Hello all,
I am fairly new to all of this. So, here is my silly question: In codecademy’s “workspace”, I was trying to process some excel spreadsheets using python. Would I be able to do that here on the codecademy “Workspace” or would I have to install my own python program to do that?
I ask, because I am using the code: names = pd.read_excel(r"C:\Users\Da_me\Documents\Test.xlsx")
to access an excel spreadsheet on my computer. However, when I do so, I get the error:
"
Traceback (most recent call last):
File “script1.py”, line 8, in
names = pd.read_excel(r"C:\Users\Da_me\Documents\Test.xlsx")
File “/usr/local/lib/python3.6/dist-packages/pandas/util/_decorators.py”, line 208, in wrapper
return func(*args, **kwargs)
File “/usr/local/lib/python3.6/dist-packages/pandas/io/excel/_base.py”, line 310, in read_excel
io = ExcelFile(io, engine=engine)
File “/usr/local/lib/python3.6/dist-packages/pandas/io/excel/_base.py”, line 819, in init
self._reader = self._enginesengine
File “/usr/local/lib/python3.6/dist-packages/pandas/io/excel/_xlrd.py”, line 20, in init
import_optional_dependency(“xlrd”, extra=err_msg)
File “/usr/local/lib/python3.6/dist-packages/pandas/compat/_optional.py”, line 93, in import_optional_dependency
raise ImportError(message.format(name=name, extra=extra)) from None
ImportError: Missing optional dependency ‘xlrd’. Install xlrd >= 1.0.0 for Excel support Use pip or conda to install xlrd.
"
I see at the bottom that I need to use “pip” to install “xlrd”, but wouldn’t that already be installed on the codecademy website or would I need it on my computer too?