Twitter Streaming API in Python. Data mining Demonstration

Veröffentlicht am: 25 Februar 2018
auf dem Kanal: Data Science Garage
1,301
16

I have made some web scrappers before. You can check it out here:
   • Another scraping project in Python: f...  
   • Regia.lt. Web Scrapping Project  Land...  
   • Python Web Scraping Real estate websi...  
and more.

It was so easy and fun work by using Beautiful Soup and Selenium.

This time I going to build a powerful Twitter scanner. Twitter provide three main APIs: the REST API, Streaming API, and the Ads API.

I will use Twitter Streaming API for gathering all related by a keyword tweets in real time. Yes - in real time!


First of all before all the work you must to create an application in your Twitter account. Then you will generate your Consumer ID, Secret keys, Token key and Token secret keys. You have to obtain credentials to be able to collect data from Twitter.

Before coding I recommend install requests-oauthlib 0.8.0 module from here: https://pypi.python.org/pypi/requests... to your default Python directory.

Good is that my code will write the real time tweets to output csv file after each tweet is come to the pocket.

Next step: implement sentimental analysis for tweets. Still searching for solutions.

Vytautas Bielinskas
LinkedIn:   / bielinskas  


Auf dieser Seite können Sie das Online-Video Twitter Streaming API in Python. Data mining Demonstration mit der Dauer stunde minuten sekunde in guter Qualität ansehen, das der Benutzer Data Science Garage 25 Februar 2018 hochgeladen hat, den Link mit Freunden und Bekannten teilen, dieses Video wurde auf Youtube bereits 1,301 Mal angesehen und es wurde von 16 den Zuschauern gefallen. Viel Spaß beim Betrachtenden Zuschauern gefallen!