How Online Narrative Played Out on Twitter Before, During and After the 2021 Uganda Elections

Uganda has an estimated 2.5 million social media users. Among the various social media platforms, Twitter, has come to have a strong influence and relevance on the country’s political discourse. Various studies have shown that Twitter data can provide useful information for tracking rapidly evolving public sentiments, measuring public interests and concerns, indicating real-time political narratives and how they change over time. However, these studies are not without limitations as they only qualitatively perform manual coding of a very small number of tweets. This research aimed to understand the perceptions and sentiments surrounding Twitter users’ discourse and reactions in the lead up, during and after the 2021 Uganda Elections. Machine learning techniques were used to analyse approximately 2.2 million tweets (written mostly in English, Luganda and local colloquialisms) related to key hashtags collected between November 01, 2020 and January 31, 2021. Of over 1,800 civic, political or election related hashtags which were identified and tracked across the two months since the presidential nominations in early November 2020, 500 purposely selected hashtags were used as seed data for the research. Another batch of 500, 000 Tweets were collected from January 01 to January 31, 2021. The perceptions and sentiments from this analysis evolved over time, driven by the interactions between offline and online events that happened between November 2020 and January 2021. The analysis examined the topics related to the tweets; the themes of these identified topics; and users’ reactions