I have installed pandas on python 3.3, and coded like this:
import csv
import pandas
from pandas import DataFrame
csvdata = pandas.read_csv(\'datafile.csv\'
I encountered the same problem. I installed pandas using command pip install pandas.
By default, my pip installed pandas in dist-packages of python3.2 and my default python version was 2.7. As a result when I did python to open the interactive shell and try to do
import pandas
File "", line 1, in
File "/usr/local/lib/python3.2/dist-packages/pandas/__init__.py", line 6, in
from . import hashtable, tslib, lib
ImportError: cannot import name hashtable
What solved my problem was:
python3.2
import pandas
Please check that the you use the same Python version whose dist-packages contain pandas.