Recurrent Twitter Trends in 2016

Mar 28, 2017 · 496 words · 3 minutes read R SQL

Since late 2013, I’ve been using the Twitter API to keep track of trending topics in Canada. With the help of a Python script and my brother’s server, I save all trending topics at intervals of 3 minutes.

Over the years this has become quite the dataset. At the time of writing it contains 574,354 timepoints, with 20 more being added every hour. And despite many ideas for how to analyze it, I’ve mostly let the data accumulate and kept fantasizing about Markov models.

To gear up for fancier analyses, I’ve started tallying the trends recorded in 2016. In total I recorded 21,886 distinct trending topics, out of a total of 1,680,950. Roughly half (10,911) of the trending topics were hashtags, and the counts for these are comparable to the counts of the other trending topics.

Recurrence Patterns

The top 15 most recurrent trends are shown in the table below. The count column gives the number of timepoints at which the topic was trending, and the Time (%) column gives the timepoint count as a percentage of all possible timepoints (168,095).

Trend Count Time (%)
#mondaymotivation 9720 5.78
#FridayFeeling 9425 5.61
#WednesdayWisdom 5920 3.52
#TravelTuesday 5371 3.20
#ThursdayThoughts 3675 2.19
#SundayFunday 3353 1.99
#TFCLive 2621 1.56
Dickey 2329 1.39
#SDLive 2320 1.38
#HTGAWM 2255 1.34
#TLMEP 2177 1.30
#DolanTwinsNewVideo 2074 1.23
Don Cherry 1978 1.18
#TheWalkingDead 1904 1.13
#onstorm 1833 1.09

Unsurprisingly, the most recurrent trends are weekday-specific. These will typically be recycled week after week. Plotting the recurrence of the top trend, #mondaymotivation, shows this pattern clearly.

#mondaymotivation

After the weekday-specific trends, the next item in the list is #TFCLive. This hashtag is used for tweets about Toronto FC, a men’s soccer team based in Toronto. The Major League Soccer regular season runs from late March to October, with playoffs running until December.

#TFCLive

Other sports-related trends, like Dickey (Blue Jays player), #SDLive (wrestling), and Don Cherry (hockey personality), show similar patterns: spikes at semi-regular intervals when the sport is in season.

Another major class of recurrent trending topic is TV shows. These topics will typically be trending when new episodes come out, resulting in weekly recurrence when the show is on air.

#HTGAWM

The least predictable recurrence pattern in the top 15 trends is the one shown by #onstorm. This hashtag is used for storms in Ontario - which occur at far less regular intervals than episodes of How to Get Away with Murder.

#onstorm

Time of Day

Finally, I looked at the time of day the weekday topics were trending. I plotted each run of consecutive timepoints where the topic was trending as a line, leaving me with all trend trajectories superimposed on the same plot.

Time of day multiplot

#mondaymotivation typically reaches its peak in the morning, between 9 am and 12 pm Toronto time. By contrast, #FridayFeeling peaks in the early afternoon, presumably a sign of people gearing up for the weekend.

Code

The code for the analysis is available on Github.

R packages: BPG, lubridate, chron, reshape2, RMySQL