Journal of King Saud University: Computer and Information Sciences (Jun 2024)

Using Twitter as a digital insight into public stance on societal behavioral dynamics

  • Aqil M. Azmi,
  • Abdulrahman I. Al-Ghadir

Journal volume & issue
Vol. 36, no. 5
p. 102078

Abstract

Read online

This study explores X’s (formerly Twitter’s) capacity to serve as a real-time barometer of public sentiment, contextualized within the transformative reforms of Saudi Arabia during 2016–2017. The objective was to decipher the populace’s response to these significant national changes by analyzing approximately 200 million tweets in native Arabic dialects, thereby aiming for an authentic portrayal of local sentiment. Our methodology entailed a dual-phase analysis: initial tweet examination to discern prevalent social behaviors, followed by stance detection to classify tweets according to their support, neutrality, or opposition to the divisive issues at hand. For sentiment extraction, we employed a sophisticated feature vector, integrating the k most frequent words and stems. A comprehensive evaluation of various classifiers was conducted, including Support Vector Machine and several variants of K-nearest neighbors (K-NN), with a particular emphasis on their applicability to our dataset. Notably, the 9-NN classifier, and more specifically, the weighted K-NN approach, demonstrated remarkable performance, achieving an F-score of 72.45%. These insights not only shed light on the public’s reception to the Saudi reforms but also position Twitter as a viable, real-time alternative to traditional survey methods for capturing the nuances of public opinion, thereby offering valuable perspectives for policy formulation.

Keywords