Error in code while doing this last assignment i.e. Course Project - Exploratory Data Analysis

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.

Use read_csv(data_dir + "/Tweet.csv") , you are missing a / before the Tweets.csv .

image

still facing same error

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.