I am trying to read data from a csv file using pandas to perform regression and other statistical operations on the data but repeatedly get this error which wasn't present earlier.
File "comp.py", line 1, in <module>
import pandas as pd
File "F:\Program Files (x86)\Python36-32\lib\site-packages\pandas\__init__.py", line 13, in <module>
__import__(dependency)
File "F:\Program Files (x86)\Python36-32\lib\site-packages\numpy\__init__.py", line 187, in <module>
from .testing import Tester
File "F:\Program Files (x86)\Python36-32\lib\site-packages\numpy\testing\__init__.py", line 10, in <module>
from unittest import TestCase
File "F:\Program Files (x86)\Python36-32\lib\unittest\__init__.py", line 64, in <module>
from .main import TestProgram, main
File "F:\Program Files (x86)\Python36-32\lib\unittest\main.py", line 4, in <module>
import argparse
File "F:\Program Files (x86)\Python36-32\lib\argparse.py", line 87, in <module>
import copy as _copy
File "F:\mathsassignment1\copy.py", line 2, in <module>
data=pandas.read_csv("Output.csv")
AttributeError: module 'pandas' has no attribute 'read_csv'
This is my original code
import numpy as np
data=pandas.read_csv('Output.csv')
I have tried changing it to data=pandas.read_table("Output.csv",sep=',')
Still the exact same error message pops up
File "F:\mathsassignment1\copy.py", line 2, in <module>
data=pandas.read_csv("Output.csv")
AttributeError: module 'pandas' has no attribute 'read_csv'
Yes, it still says
data=pandas.read_csv("Output.csv")
Even after trying to read another csv file with a different name the same error message is being
I have also tried reinstalling python, running it in Ubuntu instead of Windows, reinstalling pandas, Typing the same code again in another file . I don't have a file named pandas.py in my working directory. Please help out as soon as possible .Have wasted quite a few hours trying to figure out the problem.