dkdollykumari7
(Behind the closed doors)
February 15, 2021, 11:19am
#1
Hi ,
While doing this last assignment i.e. Course Project - Exploratory Data Analysis.
While creating directory and then extracting file from Kaggle using import pandas i m facing error which I m not able to understand.
So could you please help me out on this.
I have attached the image .
Looking forward to get response on this.
Thanks,
Shrishti kumari
maid id:dkdollykumari7@gmail.com
Dolly try with complete path ‘./tweets-about-the-top-companies-from-2015-to-2020/Tweet.csv’
you can also use os.path.join() but this is much easier to understand for a newbie.
birajde
(Biraj De)
February 16, 2021, 4:00am
#3
Use read_csv(data_dir + "/Tweet.csv")
, you are missing a /
before the Tweets.csv .
birajde
(Biraj De)
February 24, 2021, 6:32am
#5
The data_dir line in your code is either not present or not executed. You have to use the total path of the file to import the file as a dataset,
You can either do,
data_dir = "./tweets-about....."
Tweet_data = pd.read_csv(data_dir + "/Tweet.csv")
Or directly you can write,
Tweet_data = pd.read_csv("./tweets-about...../Tweet.csv")
Hope it helps.