Analyzing tweets - time series analysis

The previous sections analyzed the content of tweets. In this section, we will discuss another interesting aspect of analyzing data from Twitter-the distribution of tweets over time.

Generally speaking, a time series is a sequence of data points that consists of successive observations over a given interval of time. As Twitter provides a created_at field with the precise timestamp of the tweet, we can rearrange tweets into temporal buckets so that we can examine how users react to real-time events. We are interested in observing how a population of users is tweeting, not just a single user, so the data gathered via the Streaming API is most suited for this type of analysis.

The analysis in this section uses ...

Get Mastering Social Media Mining with Python now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.