Sentiment and Topic Modeling Analysis on Twitter Reveals Concerns over Cannabis-Containing Food after Cannabis Legalization in Thailand

Healthc Inform Res. 2023 Jul;29(3):269-279. doi: 10.4258/hir.2023.29.3.269. Epub 2023 Jul 31.

Abstract

Objectives: Twitter has been used to express a diverse range of public opinions about cannabis legalization in Thailand. The purpose of this study was to observe changes in sentiments after cannabis legalization and to investigate health-related topics discussed on Twitter.

Methods: Tweets in Thai and English related to cannabis were scraped from Twitter between May 1 and June 13, 2022, during cannabis legalization in Thailand. Sentiment and topic-modeling analyses were used to compare the content of tweets before and after legalization. Health-related topics were manually grouped into categories by their content and rated according to the number of corresponding tweets.

Results: We collected 21,242 and 6,493 tweets, respectively, for Thai and English search terms. A sharp increase in the number of tweets related to cannabis legalization was detected at the time of its public announcement. Sentiment analysis in the Thai search group showed a significant change (p < 0.0001) in sentiment distribution after legalization, with increased negative and decreased positive sentiments. A significant change was not found in the English search group (p = 0.4437). Regarding cannabis-containing food as a leading issue, topic-modeling analysis revealed public concerns after legalization in the Thai search group, but not the English one. Topics related to cannabis tourism surfaced only in the English search group.

Conclusions: Since cannabis legalization, the primary health-related concern has been cannabis-containing food. Education and clear regulations on cannabis use are required to strengthen oversight of cannabis in the Thai population, as well as among medical tourists.

Keywords: Cannabis; Legislation; Sentiment Analysis; Social Media; Thailand.