This is the repository for Data Mining Group 1 in the Summer 2021 Big Data Summer Institute at the University of Michigan. Our project focuses on implementing topic modeling methods for textual data obtained from Twitter on the topic of COVID-19 vaccination. The goal of our project is to develop a method for incorporating the sentiment of the tweets into clustering algorithms.
How do thoughts about vaccine mandates on college campuses vary between tweets with different levels of vaccine sentiments and vaccine acceptance?
Jamie Forschmiedt, Darren Lin, Tannistha Mondal, Jakob Woerner
Dr. Johann Gagnon-Bartsch, Juejue Wang, Heather Johnston
-
Download tweets with
0_Downloading Tweets to a CSV.ipynb(You can skip this if you already have the tweets downloaded) -
Determine sentiments with
1_vader_r.Rmd -
Classify pro-vaccine or anti-vaccine with
2_Random Forest Labeling.ipynb -
Clean up and create document-term matrices with
3_data preprocessing modified.R. After this, you should get 5 data filesdtm_all.csvcontains all the tweets, the document-term matrix, the vaccine acceptance labels, and the vaccine sentiment labels.df_VA1_s1.csv,df_VA0_s1.csv1,df_VA1_s0.csv, anddf_VA0_s0.csvcontain tweets separated by vaccine acceptance (positive = 1, negative = 0) and sentiment label (positive = 1, negative = 0)
-
Cluster using the files from step 3. Use
4_monocle3.Rif the file has more than 300 observations; use4_k medoids.Rif DTM has less than 300 observations. -
(Optional) If you find that a cluster created in
4_monocle3.Ris much larger than the other clusters, you rerun4_monocle3.Ron just the large cluster.