Before diving into details, here are the key parts of the projects:
- Create an account on Twitter
- Use Tweepy to scrap the Tweets
- Create a Panda DataFrame
- Sentiment analysis
- Word frequency analysis
In order to access Twitter Streaming API, we need to get 4 pieces of information from Twitter: API key, API secret, Access token and Access token secret. But for that we need to create a twitter account. So create an account if you don't already have one.
The file explorer is accessible using the button in left corner of the navigation bar. You can create a new file by clicking the New file button in the file explorer. You can also create folders by clicking the New folder button.
- Go to https://apps.twitter.com/ and log in with your twitter credentials.
- Click "Create New App"
- Fill out the form, agree to the terms, and click "Create your Twitter application"
- In the next page, click on "API keys" tab, and copy your "API key" and "API secret".
- Scroll down and click "Create my access token", and copy your "Access token" and "Access token secret".
Tweepy is easy-to-use Python library for accessing the Twitter API. (pip install tweepy)