fbpx

Real-Time Analysis of Sentiment in Political Speeches

By Orisys Academy on 19th January 2024

Problem statement

Understanding public sentiment towards political speeches is crucial for political
campaigns and policymakers. Real-time analysis of sentiment in political
speeches can provide insights into public reactions and perceptions.

Abstract

This project aims to implement a real-time sentiment analysis system for
political speeches. Utilizing natural language processing and machine learning,
the system will analyze the sentiment expressed in political speeches as they
occur, offering timely insights into public reactions.

Outcome

A real-time sentiment analysis tool for political speeches that assists political
campaigns, policymakers, and analysts in understanding and responding to
public sentiment in real-time.

Reference

The use of sentiment analysis methods has increased in recent years across a wide range of disciplines. Despite the potential impact of the development of opinions during political elections, few studies have focused on the analysis of sentiment dynamics and their characterization from statistical and mathematical perspectives. In this paper, we apply a set of basic methods to analyze the statistical and temporal dynamics of sentiment analysis on political campaigns and assess their scope and limitations.
To this end, we gathered thousands of Twitter messages mentioning political parties and their leaders posted several weeks before and after the 2019 Spanish presidential election. We then followed a twofold analysis strategy: (1) statistical characterization using indices derived from well-known temporal and information metrics and methods –including entropy, mutual information, and the Compounded Aggregated Positivity Index– allowing the estimation of changes in the density function of sentiment data; and (2) feature extraction from nonlinear intrinsic patterns in terms of manifold learning using autoencoders and stochastic embeddings. The results show that both the indices and the manifold features provide an informative characterization of the sentiment dynamics throughout the election period. We found measurable variations in sentiment behavior and polarity across the political parties and their leaders and observed different dynamics depending on the parties’ positions on the political spectrum, their presence at the regional or national levels, and their nationalist or globalist aspirations.

  1. M. Rodríguez-Ibáñez, F.-J. Gimeno-Blanes, P. M. Cuenca-Jiménez, S. Muñoz-Romero, C. Soguero, and J. L. Rojo–Álvarez, ‘‘On the statistical and temporal dynamics of sentiment analysis,’’ IEEE Access, vol. 8, pp. 87994–88013, 2020.


  2. M. P. Anto, M. Antony, K. M. Muhsina, N. Johny, V. James, and A. Wilson, ‘‘Product rating using sentiment analysis,’’ in Proc. Int. Conf. Elect., Electron., Optim. Techn., Mar. 2016, pp. 3458–3462.

  3. A. Porshnev, I. Redkin, and A. Shevchenko, ‘‘Machine learning in prediction of stock market indicators based on historical data and data from Twitter sentiment analysis,’’ in Proc. IEEE 13th Int. Conf. Data Mining Workshops, Dec. 2013, pp. 440–444.