ImportError openpyxl is required for loading excel format files

0 votes

I am using anaconda spyder 2.7 on windows 10 64 bit. I am also using psychopy software. There is an error coming which says openpyxl is required to load excel format files. I have installed openpyxl, but still there is a same error. I have also tried to modify the line 29:

openpyxl.cell import get_column_letter 
openpyxl.utils import get_column_letter

but there is no difference. I am sending you the code and traceback. It would be really helpful if someone can solve this error.

base_dir =  os.path.normpath('C:\\Users\\ravikumar.mevada\\Gustometer\\qmix\\examples')
conditions_file = os.path.join(base_dir, 'fat_taste.xlsx')
data_dir = os.path.join(base_dir, 'Data_out_fat')
outfile = os.path.join(data_dir,'output_fat_taste')

#import .xlsx file
conditions = data.importConditions(conditions_file)

#screen resolution #TODO: not used
width = GetSystemMetrics(0) 
height = GetSystemMetrics(1)

#assign to each taste a specific pump
tastants_pumps = {'sweet1':pump_1,'sweet2':pump_3,'sweet3':pump_4, 'water':pump_5}
Traceback (most recent call last):

 File "<ipython-input-9-291e52893b5d>", line 7, in <module>
conditions = data.importConditions(conditions_file)

 File "C:\Users\ravikumar.mevada\Anaconda2\lib\site-packages\psychopy\", line 2667, in importConditions
 raise ImportError('openpyxl is required for loading excel '

 ImportError: openpyxl is required for loading excel format files, but it was not found. 

Oct 3, 2018 in Python by eatcodesleeprepeat
• 4,710 points

1 answer to this question.

0 votes

Forget the PsychoPy complications for the time time being, this just sounds like a problem with the installation of openpyxl. i.e. what happens with a python script that contains nothing but the line import openpyxl

If that doesn't work try re-installing it. It might work fine.

answered Oct 3, 2018 by Priyaj
• 58,090 points

Related Questions In Python

0 votes
1 answer

What data format for large files in R?

Zipping won't help you, as you'll have ...READ MORE

answered Jul 16, 2019 in Python by SDeb
• 13,300 points
0 votes
1 answer

Is there a built-in module to handle excel files in python?

You can use the module - openpyxl ...READ MORE

answered Aug 19, 2019 in Python by Mohammad
• 3,230 points
+1 vote
1 answer

What is the correct order to learn concepts in Python for machine learning?

Machine Learning is a vast domain. It ...READ MORE

answered Jul 25, 2018 in Python by Abhi
• 3,720 points
0 votes
1 answer

What is the Python equivalent for a case/switch statement?

if x == 'a':  # Do the ...READ MORE

answered Jul 26, 2018 in Python by Priyaj
• 58,090 points
0 votes
2 answers
+1 vote
2 answers

how can i count the items in a list?

Syntax :            list. count(value) Code: colors = ['red', 'green', ...READ MORE

answered Jul 7, 2019 in Python by Neha
• 330 points

edited Jul 8, 2019 by Kalgi 4,203 views
0 votes
1 answer
+1 vote
1 answer

Why is openpyxl is required for loading excel format files?

Well, it sounds like openpyxl is not ...READ MORE

answered Aug 8, 2018 in Python by Priyaj
• 58,090 points
0 votes
1 answer

What is the flow control for “continue” in python?

This is the way "continue" statement works! You ...READ MORE

answered Jul 16, 2018 in Python by Priyaj
• 58,090 points
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP