Next Article in Journal
The Impact of Resilience on Post-Traumatic Growth among Nurses in COVID-19-Designated Hospitals: The Mediating Effect of Meaning in Life
Previous Article in Journal
Psychological Symptoms in Parents Who Experience Child-to-Parent Violence: The Role of Self-Efficacy Beliefs
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Sentiments about Mental Health on Twitter—Before and during the COVID-19 Pandemic

1
National Institute of Informatics, Tokyo 101-8430, Japan
2
Institute of Clinical Epidemiology and Biometry (ICE-B), University of Würzburg, 97074 Würzburg, Germany
*
Author to whom correspondence should be addressed.
Healthcare 2023, 11(21), 2893; https://doi.org/10.3390/healthcare11212893
Submission received: 12 September 2023 / Revised: 23 October 2023 / Accepted: 1 November 2023 / Published: 3 November 2023

Abstract

During the COVID-19 pandemic, the novel coronavirus had an impact not only on public health but also on the mental health of the population. Public sentiment on mental health and depression is often captured only in small, survey-based studies, while work based on Twitter data often only looks at the period during the pandemic and does not make comparisons with the pre-pandemic situation. We collected tweets that included the hashtags #MentalHealth and #Depression from before and during the pandemic (8.5 months each). We used LDA (Latent Dirichlet Allocation) for topic modeling and LIWC, VADER, and NRC for sentiment analysis. We used three machine-learning classifiers to seek evidence regarding an automatically detectable change in tweets before vs. during the pandemic: (1) based on TF-IDF values, (2) based on the values from the sentiment libraries, (3) based on tweet content (deep-learning BERT classifier). Topic modeling revealed that Twitter users who explicitly used the hashtags #Depression and especially #MentalHealth did so to raise awareness. We observed an overall positive sentiment, and in tough times such as during the COVID-19 pandemic, tweets with #MentalHealth were often associated with gratitude. Among the three classification approaches, the BERT classifier showed the best performance, with an accuracy of 81% for #MentalHealth and 79% for #Depression. Although the data may have come from users familiar with mental health, these findings can help gauge public sentiment on the topic. The combination of (1) sentiment analysis, (2) topic modeling, and (3) tweet classification with machine learning proved useful in gaining comprehensive insight into public sentiment and could be applied to other data sources and topics.
Keywords: COVID-19; coronavirus; public health; sentiment analysis; topic modeling; machine learning COVID-19; coronavirus; public health; sentiment analysis; topic modeling; machine learning

Share and Cite

MDPI and ACS Style

Beierle, F.; Pryss, R.; Aizawa, A. Sentiments about Mental Health on Twitter—Before and during the COVID-19 Pandemic. Healthcare 2023, 11, 2893. https://doi.org/10.3390/healthcare11212893

AMA Style

Beierle F, Pryss R, Aizawa A. Sentiments about Mental Health on Twitter—Before and during the COVID-19 Pandemic. Healthcare. 2023; 11(21):2893. https://doi.org/10.3390/healthcare11212893

Chicago/Turabian Style

Beierle, Felix, Rüdiger Pryss, and Akiko Aizawa. 2023. "Sentiments about Mental Health on Twitter—Before and during the COVID-19 Pandemic" Healthcare 11, no. 21: 2893. https://doi.org/10.3390/healthcare11212893

APA Style

Beierle, F., Pryss, R., & Aizawa, A. (2023). Sentiments about Mental Health on Twitter—Before and during the COVID-19 Pandemic. Healthcare, 11(21), 2893. https://doi.org/10.3390/healthcare11212893

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop