Question: Twitter data analysis I by using tweepy , i need python code to get twitter tweets from Arabic hashtag with all preprocessing i will need
Assignment Objectives By the completion of this assignment you should be able to: - Collect Tweets using any Python library of your choice that is tailored for dealing with Twitter API such as: - twitter: (pip install twitter, or, pip install python-twitter). - tweepy: (pip3 install tweepy), please make sure that you already installed Python 3 on your system. - Analyze the tweets using various methods including term frequency and TF-IDF. Introduction Attached with this document a python file called getSomeTweets.py. In this python file, you will connect to twitter API using OAuth protocol. If you decided to use tweepy, you can use the code as is as a starting point. But make sure first to install the relevant packages by saving the attached file named requirements. txt and call it from the directory in which it resides with pip as follow: pip install x requirements.txt Before going further, you must read the code (which is documented to understand what is going on and what are you required to do in the following Tasks. Required Tasks: 1. First, fill your OAuth credentials and run the code. Make sure that you got two datasets (csv files) named twitterArabicData.csv and twitterEnglishData.csv as the result. Also make sure that they are not empty. 2. Start exploring the data by installing and/or importing any python package that you think it might help you in achieving the rest of the tasks. 3. Create a basic word frequency count for each dataset (independently), then choose an easily human readable format such as table or a graph to show the result, then try interpreting the numbers in your own words. 4. Calculate the lexical diversity of tweets of each dataset. Then, discuss the results
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
