Data Science and Visualizations

Social Media Derived Racial Sentiment Measures

Racial Sentiment

Health EquityPublic HealthMachine LearningNatural Language ProcessingOpen ScienceSocial MediaVital StatisticsPythonR

Survey measures of population attitudes are expensive, infrequent, and coarse in geography. That makes them awkward as an exposure variable in health research, where you often want to know what the social environment looked like in a particular place at a particular time.

Our group developed an alternative: derive area-level, time-resolved sentiment measures from social media at scale. The pipeline collects topic-referencing posts, applies machine learning sentiment classification, and aggregates to geographic and temporal units that can be joined to health data. We published the method with full technical guidance and code so other groups could replicate it rather than rebuild it — the point was to make the approach usable, not to hold it.

  1. Nguyen, T. T., Merchant, J. S., Makres, K., Dennard, E., Criss, S., & Nguyen, Q. C. (2026). SOCIAL MEDIA AND MENTAL HEALTH. From Posts to Patterns: Using Social Media to Investigate Drivers of Population Health, 146.
  2. Nguyen, T. T., Merchant, J. S., Yue, X., Mane, H., Wei, H., Huang, D., … & Nguyen, Q. C. (2024). A Decade of Tweets: Visualizing Racial Sentiments Towards Minoritized Groups in the United States Between 2011 and 2021. Epidemiology, 35(1), 51-59.
  3. Nguyen, T. T., Yue, X., Mane, H., Seelman, K., … Merchant, J. S., … & Nguyen, Q. C. (2025). Decoding digital discourse through multimodal text and image machine learning models to classify sentiment and detect hate speech in race-and lesbian, Gay, bisexual, transgender, queer, intersex, and asexual community–related posts on social media: Quantitative study. Journal of Medical Internet Research, 27, e72822.

Interactive Data Dashboards

Intersectional Youth Mental Health Disparities in the CDC’s Youth Risk Behavior Survey data