Error reading csv file in python

0 votes

Hi. I am new to python and I am trying to read a csv file. I am using pandas library for reading it. This is my code

import pandas as pd
filedata = pd.read_csv(“/home/user/data1”)

But I am getting file not found error

Mar 28 in Python by Preeti

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

You are missing the extension. Try this:

import pandas as pd
filedata = pd.read_csv(“/home/user/data1.csv”)
answered Mar 28 by Shri

Related Questions In Python

+1 vote
1 answer

Reading a large file, line by line in Python

The correct, fully Pythonic way to read ...READ MORE

answered Aug 21, 2018 in Python by Priyaj
• 56,120 points
0 votes
0 answers

cannot read a csv file in python

i am getting an error reading a ...READ MORE

Mar 5 in Python by Mohammad
• 1,400 points
0 votes
1 answer

Reading a CSV file using Python 3

A simple "if" statement should suffice. you ...READ MORE

answered Mar 26 in Python by SDeb
• 9,660 points
+3 votes
7 answers

How can I rename a file in Python?

yes, you can use "os.rename" for that. ...READ MORE

answered Mar 31, 2018 in Python by DareDev
• 6,560 points
0 votes
1 answer

how can i count the items in a list?

suppose you have a list a = [0,1,2,3,4,5,6,7,8,9,10] now ...READ MORE

answered May 2 in Python by Mohammad
• 1,400 points
+4 votes
6 answers
0 votes
1 answer

How to find the value of a row in a csv file in python?

If you want to find the value ...READ MORE

answered 6 days ago in Python by Sanam
0 votes
2 answers

Extracting data from a JSON file in Python

Here is what i found and was ...READ MORE

answered Nov 27, 2018 in Python by Rupali

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.