Analyzing a social network with NetworkX
In this recipe, we will show how to analyze social data in Python. Social data is generated by people's activity on social networks such as Facebook, Twitter, Google+, GitHub, and others.
In this recipe, we will analyze and visualize a Twitter user's social network with NetworkX.
Getting ready
First, you need to install the Twitter Python package. You can install it with pip install twitter
. You'll find more information at https://pypi.python.org/pypi/twitter.
Then, you need to obtain authentication codes in order to access your Twitter data. The procedure is free. In addition to a Twitter account, you also need to create an Application on the Twitter Developers website at https://dev.twitter.com/apps. Then, ...
Get IPython Interactive Computing and Visualization Cookbook now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.