Sentiment Analysis for Starbucks Stock Price Prediction Using VADER and ARIMAX

Widyanti Rahayu, Gabriel Olivia Yvonne Manurung, Eti Dwi Wiraningsih, VERA MAYA SANTI

Abstract


The escalation of the Israel–Palestine conflict in October 2023 generated extensive public reactions worldwide, particularly on social media platforms. On October 9, 2023, a statement supporting Palestine posted by the Starbucks Workers United union on X (Twitter) prompted legal action from Starbucks. Although the dispute was related to trademark and intellectual property issues, public interpretation associated the lawsuit with opposition to pro-Palestinian support, leading to boycott campaigns in several countries. This situation coincided with a notable decline in Starbucks’ stock performance, including an eleven-day consecutive decrease in December 2023. Given the growing influence of online discussions on financial markets, social media sentiment may provide valuable information for stock price forecasting. Using a quantitative time-series forecasting approach, this study aims to analyze public sentiment toward Starbucks associated with the boycott movement, develop an ARIMAX model incorporating sentiment as an exogenous variable for stock price forecasting, and evaluate the predictive performance of the proposed model. A total of 41,211 English-language posts containing the keyword “boycott Starbucks” were collected from X between October 2023 and December 2024, while stock market data were obtained from Yahoo Finance through the yfinance library. Sentiment classification was conducted using the VADER approach, followed by ARIMAX modeling and forecast evaluation using Mean Absolute Percentage Error (MAPE) and Mean Squared Error (MSE). The results indicate that negative sentiment dominated the discussions (54%), followed by positive (43.3%) and neutral sentiment (2.7%), with the highest activity occurring in December 2023. Based on the minimum AIC and BIC values, ARIMAX(3,0,3) was selected as the best model and satisfied all diagnostic assumptions. Forecasting for the period January 2–16, 2025 produced a MAPE of 1.97% and an MSE of 3.58, indicating high forecasting accuracy. The findings highlight the potential of incorporating social media sentiment as an external information source in ARIMAX-based stock price forecasting, particularly during periods of heightened public attention triggered by major socio-political events.

Keywords


Sentiment Analysis; VADER; ARIMAX; Stock Price Forecasting.

Full Text:

DOWNLOAD [PDF]

References


Akaike, H. (1998). Information Theory and an Extension of the Maximum Likelihood Principle. In K. and K. G. Parzen Emanuel and Tanabe (Ed.), Selected Papers of Hirotugu Akaike (pp. 199–213). Springer New York. https://doi.org/10.1007/978-1-4612-1694-0_15

Albrecht, C.-M., Campbell, C., Heinrich, D., & Lammel, M. (2013). Exploring why consumers engage in boycotts: Toward a unified model. Journal of Public Affairs, 13(2), 180–189. https://doi.org/10.1002/pa.1473

Borg, A., & Boldt, M. (2020). Using VADER sentiment and SVM for predicting customer response sentiment. Expert Systems with Applications, 162, 113746. https://doi.org/10.1016/j.eswa.2020.113746

Breusch, T. S., & Pagan, A. R. (1979). A Simple Test for Heteroscedasticity and Random Coefficient Variation. Econometrica, 47(5), 1287–1294. https://doi.org/10.2307/1911963

Chicco, D., Warrens, M., & Jurman, G. (2021). The coefficient of determination R-squared is more informative than SMAPE, MAE, MAPE, MSE and RMSE in regression analysis evaluation. PeerJ Computer Science, 7, e623. https://doi.org/10.7717/peerj-cs.623

Cryer, J. D., & Chan, K. S. (2008). Time Series Analysis: With Applications in R (2nd ed.). Springer.

Fekrazad, A., Harun, S. M., & Sardar, N. (2022). Social media sentiment and the stock market. Journal of Economics and Finance, 46(2), 397–419. https://doi.org/10.1007/s12197-022-09575-x

Holzhauer, H. M., Lu, X., McLeod, R., & Wang, J. (2016). RiskTRACK: The Five-Factor Model for Measuring Risk Tolerance. The Journal of Risk Finance, 17(4), 428–445. https://doi.org/10.1108/JRF-04-2016-0054

Hutto, C., & Gilbert, E. (2014). VADER: A parsimonious rule-based model for sentiment analysis of social media text. Proceedings of the International AAAI Conference on Web and Social Media, 8(1), 216–225. https://doi.org/10.1609/icwsm.v8i1.14550

Ibrahim, M., & Alturfi, A. (2022). Impact of exogenous and endogenous variables in time series analysis, exchange rate in turkey as case study. International Journal of Statistics and Applied Mathematics, 7(5), 10–14. https://doi.org/10.22271/maths.2022.v7.i5a.874

Investing.com. (2025). Starbucks Corporation Income Statement. https://id.investing.com/equities/starbucks-corp-income-statement

Ivanenko, V. (2023). Assessing Social Media’s Impact on Stock Market Predictions: Financial Sentiment Embedding Approaches. The 13th International Conference on Dependable Systems, Services and Technologies (DESSERT), 1–6. https://doi.org/10.1109/DESSERT61349.2023.10416463

Khan, W., Malik, U., Ghazanfar, M. A., Azam, M. A., Alyoubi, K. H., & Alfakeeh, A. S. (2020). Predicting stock market trends using machine learning algorithms via public sentiment and political situation analysis. Soft Computing, 24(15), 11019–11043. https://doi.org/10.1007/s00500-019-04347-y

Laurente Blanco, L. F., & Machaca Hancco, R. W. (2020). Modeling and forecasting international tourism demand in Puno - Peru. Revista Brasileira de Pesquisa Em Turismo, 14, 34–55. https://doi.org/10.7784/rbtur.v14i1.1606

Mawarnie, H. P., Widodo, & Nugraheni, M. (2024). Sentiment Analysis Twitter (X) Users Towards the Boycott of Pro-Israel Brand Using Support Vector Machine Method with SMOTE Approach. 2024 IEEE International Conference on Control & Automation, Electronics, Robotics, Internet of Things, and Artificial Intelligence (CERIA), 1–6. https://doi.org/10.1109/CERIA64726.2024.10914878

Pavan Kumar M R, & Prabhu, J. (2018). Role of sentiment classification in sentiment analysis: a survey. Annals of Library and Information Studies (ALIS), 65(3), 196–209. https://doi.org/10.56042/alis.v65i3.21598

Pokhrel, A., & Adhikari, R. (2023). Leveraging Exogenous Insights: A Comparative Forecast of Paddy Production in Nepal Using ARIMA and ARIMAX Models. Economic Review of Nepal, 6(1), 52–69. https://doi.org/10.3126/ern.v6i1.67970

Ranco, G., Aleksovski, D., Caldarelli, G., Grčar, M., & Mozetič, I. (2015). The effects of twitter sentiment on stock price returns. PLoS ONE, 10(9). https://doi.org/10.1371/journal.pone.0138441

Santi, V. M., Baihaqi, A., & Siregar, D. (2025). Modeling Poverty In West Java Province Using Negative Binomial Regression With Penalized Smoothly Clipped Absolute Deviation. Barekeng, 19(4), 2557–2570. https://doi.org/10.30598/barekengvol19no4pp2557-2570

Santi, V. M., Notodiputro, K. A., Indahwati, & Sartono, B. (2022). Restricted Maximum Likelihood Estimation For Multivariate Linear Mixed Model In Analyzing Pisa Data For Indonesian Students. Barekeng, 16(2), 607–614. https://doi.org/10.30598/barekengvol16iss2pp607-614

Santi, V. M., Notodiputro, K. A., Indahwati, Sartono, B., Susetyo, B., & Kurnia, A. (2026). Two-Level Random Effects in Multivariate Linear Mixed Model for Longitudinal Data. Engineering Letters, 34(1), 368–379. https://openurl.ebsco.com/EPDB%3Agcd%3A16%3A619312/detailv2?sid=ebsco%3Aplink%3Ascholar&id=ebsco%3Agcd%3A190639054&crl=f&link_origin=www.google.com

Santi, V. M., Notodiputro, K. A., & Sartono, B. (2019). Variable selection methods applied to the mathematics scores of Indonesian students based on convex penalized likelihood. Journal of Physics: Conference Series, 1402(7). https://doi.org/10.1088/1742-6596/1402/7/077096

Santi, V. M., Notodiputro, K. A., Sartono, B., & Rahyu, W. (2021). Generalized Linear Mixed Models by penalized Lasso in modelling the scores of Indonesian students. Journal of Physics: Conference Series, 1869(1). https://doi.org/10.1088/1742-6596/1869/1/012140

Santi, V., Wahyu, R., & Hadi, I. (2023). Forecasting the Value of Indonesia’s Oil and Gas Imports Using Seasonal Autoregressive Integrated Moving Average Model. BAREKENG: Jurnal Ilmu Matematika Dan Terapan, 17, 2047–2058. https://doi.org/10.30598/barekengvol17iss4pp2047-2058

Schwarz, G. (1978). Estimating the Dimension of a Model. The Annals of Statistics, 6(2), 461–464. https://doi.org/10.1214/aos/1176344136

Sharma, A., Tiwari, P., Gupta, A., & Garg, P. (2021). Use of LSTM and ARIMAX algorithms to analyze impact of sentiment analysis in stock market prediction. Intelligent Data Communication Technologies and Internet of Things: Proceedings of ICICI 2020, 57, 377–394. https://doi.org/10.1007/978-981-15-9509-7_32

Thadewald, T., & Büning, H. (2007). Jarque–Bera Test and its Competitors for Testing Normality – A Power Comparison. Journal of Applied Statistics, 34(1), 87–105. https://doi.org/10.1080/02664760600994539

Tiao, G. C., & Box, G. E. P. (1981). Modeling Multiple Time Series with Applications. Journal of the American Statistical Association, 76(376), 802–816. https://doi.org/10.2307/2287575

Wang, J., Ji, T., & Li, M. (2021). A Combined Short-Term Forecast Model of Wind Power Based on Empirical Mode Decomposition and Augmented Dickey-Fuller Test. Journal of Physics: Conference Series, 2022(1), 12017. https://doi.org/10.1088/1742-6596/2022/1/012017

Wang, P.-C., & Vo, T. T. H. (2025). Stock price prediction based on dual important indicators using ARIMAX: A case study in Vietnam. Journal of Intelligent Systems, 34(1), 20240101. https://doi.org/10.1515/jisys-2024-0101

Wei, W. (2006). Time Series Analysis: Univariate and Multivariate Methods. In TIME SERIES ANALYSIS (2nd ed.).




DOI: https://doi.org/10.31764/jtam.v10i4.39002

Refbacks

  • There are currently no refbacks.


Copyright (c) 2026 Widyanti Rahayu, Gabriel Olivia Yvonne Manurung, Eti Dwi Wiraningsih, Vera Maya Santi

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

_______________________________________________

JTAM already indexing:


_______________________________________________

Creative Commons License

JTAM (Jurnal Teori dan Aplikasi Matematika)
is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License

______________________________________________

_______________________________________________

_______________________________________________

JTAM (Jurnal Teori dan Aplikasi Matematika) Editorial Office: