Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added .DS_Store
Binary file not shown.
Empty file added mini-project/.Rhistory
Empty file.
36 changes: 36 additions & 0 deletions mini-project/Hoa_Ly_Idea1.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
<!DOCTYPE html><html><head><meta charset="utf-8"><title>Hoa Ly - DATA 400 Spring 2026.md</title><style></style></head><body id="preview">
<h1 class="code-line" data-line-start=0 data-line-end=1 ><a id="Hoa_Ly__DATA_400_Spring_2026_0"></a>Hoa Ly - DATA 400 Spring 2026</h1>
<h2 class="code-line" data-line-start=1 data-line-end=2 ><a id="Idea_1_1"></a>Idea 1</h2>
<p class="has-line-data" data-line-start="2" data-line-end="3">As the world continues to develop, mental health has become one of the most pressing concerns in modern society. Mental health directly affects daily life, social relationships, and an individual’s work performance. According to previous research, there are many factors that influence a person’s mental health, including living environment, family upbringing, and peer relationships. Among these factors, in an era of rapid technological advancement, social media has emerged as an important element that can impact an individual’s mental health. Therefore, in this mini project, we aim to examine how social media influences mental health.</p>
<h2 class="code-line" data-line-start=3 data-line-end=4 ><a id="Research_question_3"></a>Research question</h2>
<p class="has-line-data" data-line-start="4" data-line-end="5"><strong>How does social media affect mental heatlh ?</strong></p>
<h2 class="code-line" data-line-start=5 data-line-end=6 ><a id="Data_5"></a>Data</h2>
<p class="has-line-data" data-line-start="6" data-line-end="7">For this mini project, I will be using a dataset from Kaggle since I could not find any dataset from any other mental health organization.(<a href="https://www.kaggle.com/datasets/souvikahmed071/social-media-and-mental-health/data">Dataset</a>)</p>
<h2 class="code-line" data-line-start=7 data-line-end=8 ><a id="Model_7"></a>Model</h2>
<p class="has-line-data" data-line-start="8" data-line-end="9">This project will use a Multiple Linear Regression model and a Random Forest model.</p>
<h2 class="code-line" data-line-start=9 data-line-end=10 ><a id="Implications_for_stakeholders_9"></a>Implications for stakeholders</h2>
<ul>
<li class="has-line-data" data-line-start="10" data-line-end="13"><strong>Social Media users</strong>:
<ul>
<li class="has-line-data" data-line-start="11" data-line-end="12">The findings might help promoting that mindful and intentional social media use help reduce anxiety, depressive symptoms, and sleep disturbances.</li>
<li class="has-line-data" data-line-start="12" data-line-end="13">Specific social media behaviors (e.g., frequent social comparison, validation-seeking, restlessness when not using social media) are more strongly associated with negative mental health outcomes than overall time spent online.</li>
</ul>
</li>
<li class="has-line-data" data-line-start="13" data-line-end="16"><strong>Mental Health Professionals</strong>:
<ul>
<li class="has-line-data" data-line-start="14" data-line-end="15">Predictive patterns identified by the regression and random forest models suggest that certain social media behaviors may serve as indicators of elevated mental health risk.</li>
<li class="has-line-data" data-line-start="15" data-line-end="16">Clinicians may incorporate discussions of social media habits into screening, assessment, or therapeutic interventions.</li>
</ul>
</li>
<li class="has-line-data" data-line-start="16" data-line-end="20"><strong>Educational Institutions</strong>
<ul>
<li class="has-line-data" data-line-start="17" data-line-end="18">Colleges and schools can use these findings to inform digital wellness programs and student support services.</li>
<li class="has-line-data" data-line-start="18" data-line-end="20">Interventions may be more effective if they focus on reducing harmful engagement patterns rather than encouraging complete disengagement from social media.</li>
</ul>
</li>
</ul>
<h2 class="code-line" data-line-start=20 data-line-end=21 ><a id="Ethical_Legal_Societal_Implications_20"></a>Ethical, Legal, Societal Implications</h2>
<p class="has-line-data" data-line-start="21" data-line-end="23">I cannot really think of anything for now.<br>
Will need to meet with you so we can discuss this.</p>

</body></html>
36 changes: 36 additions & 0 deletions mini-project/Hoa_Ly_Idea1.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
<!DOCTYPE html><html><head><meta charset="utf-8"><title>Hoa Ly - DATA 400 Spring 2026.md</title><style></style></head><body id="preview">
<h1 class="code-line" data-line-start=0 data-line-end=1 ><a id="Hoa_Ly__DATA_400_Spring_2026_0"></a>Hoa Ly - DATA 400 Spring 2026</h1>
<h2 class="code-line" data-line-start=1 data-line-end=2 ><a id="Idea_1_1"></a>Idea 1</h2>
<p class="has-line-data" data-line-start="2" data-line-end="3">As the world continues to develop, mental health has become one of the most pressing concerns in modern society. Mental health directly affects daily life, social relationships, and an individual’s work performance. According to previous research, there are many factors that influence a person’s mental health, including living environment, family upbringing, and peer relationships. Among these factors, in an era of rapid technological advancement, social media has emerged as an important element that can impact an individual’s mental health. Therefore, in this mini project, we aim to examine how social media influences mental health.</p>
<h2 class="code-line" data-line-start=3 data-line-end=4 ><a id="Research_question_3"></a>Research question</h2>
<p class="has-line-data" data-line-start="4" data-line-end="5"><strong>How does social media affect mental heatlh ?</strong></p>
<h2 class="code-line" data-line-start=5 data-line-end=6 ><a id="Data_5"></a>Data</h2>
<p class="has-line-data" data-line-start="6" data-line-end="7">For this mini project, I will be using a dataset from Kaggle since I could not find any dataset from any other mental health organization.(<a href="https://www.kaggle.com/datasets/souvikahmed071/social-media-and-mental-health/data">Dataset</a>)</p>
<h2 class="code-line" data-line-start=7 data-line-end=8 ><a id="Model_7"></a>Model</h2>
<p class="has-line-data" data-line-start="8" data-line-end="9">This project will use a Multiple Linear Regression model and a Random Forest model.</p>
<h2 class="code-line" data-line-start=9 data-line-end=10 ><a id="Implications_for_stakeholders_9"></a>Implications for stakeholders</h2>
<ul>
<li class="has-line-data" data-line-start="10" data-line-end="13"><strong>Social Media users</strong>:
<ul>
<li class="has-line-data" data-line-start="11" data-line-end="12">The findings might help promoting that mindful and intentional social media use help reduce anxiety, depressive symptoms, and sleep disturbances.</li>
<li class="has-line-data" data-line-start="12" data-line-end="13">Specific social media behaviors (e.g., frequent social comparison, validation-seeking, restlessness when not using social media) are more strongly associated with negative mental health outcomes than overall time spent online.</li>
</ul>
</li>
<li class="has-line-data" data-line-start="13" data-line-end="16"><strong>Mental Health Professionals</strong>:
<ul>
<li class="has-line-data" data-line-start="14" data-line-end="15">Predictive patterns identified by the regression and random forest models suggest that certain social media behaviors may serve as indicators of elevated mental health risk.</li>
<li class="has-line-data" data-line-start="15" data-line-end="16">Clinicians may incorporate discussions of social media habits into screening, assessment, or therapeutic interventions.</li>
</ul>
</li>
<li class="has-line-data" data-line-start="16" data-line-end="20"><strong>Educational Institutions</strong>
<ul>
<li class="has-line-data" data-line-start="17" data-line-end="18">Colleges and schools can use these findings to inform digital wellness programs and student support services.</li>
<li class="has-line-data" data-line-start="18" data-line-end="20">Interventions may be more effective if they focus on reducing harmful engagement patterns rather than encouraging complete disengagement from social media.</li>
</ul>
</li>
</ul>
<h2 class="code-line" data-line-start=20 data-line-end=21 ><a id="Ethical_Legal_Societal_Implications_20"></a>Ethical, Legal, Societal Implications</h2>
<p class="has-line-data" data-line-start="21" data-line-end="23">I cannot really think of anything for now.<br>
Will need to meet with you so we can discuss this.</p>

</body></html>
32 changes: 32 additions & 0 deletions mini-project/Hoa_Ly_Idea2.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<!DOCTYPE html><html><head><meta charset="utf-8"><title>Hoa Ly - DATA 400 Spring 2026.md</title><style></style></head><body id="preview">
<h1 class="code-line" data-line-start=0 data-line-end=1 ><a id="Hoa_Ly__DATA_400_Spring_2026_0"></a>Hoa Ly - DATA 400 Spring 2026</h1>
<h2 class="code-line" data-line-start=1 data-line-end=2 ><a id="Idea_2_1"></a>Idea 2</h2>
<p class="has-line-data" data-line-start="2" data-line-end="3">Sentimental analysis of comments on Reddit</p>
<h2 class="code-line" data-line-start=3 data-line-end=4 ><a id="Research_question_3"></a>Research question</h2>
<p class="has-line-data" data-line-start="4" data-line-end="5"><strong>How can we predict a person’s mental health based on what they say on the internet ?</strong></p>
<h2 class="code-line" data-line-start=5 data-line-end=6 ><a id="Data_5"></a>Data</h2>
<p class="has-line-data" data-line-start="6" data-line-end="7">For this idea, I will be scraping data from Reddit.</p>
<h2 class="code-line" data-line-start=7 data-line-end=8 ><a id="Model_7"></a>Model</h2>
<p class="has-line-data" data-line-start="8" data-line-end="9">I plan to use Twitter-roberta-based-sentiment model for the project.</p>
<h2 class="code-line" data-line-start=9 data-line-end=10 ><a id="Implications_for_stakeholders_9"></a>Implications for stakeholders</h2>
<ul>
<li class="has-line-data" data-line-start="10" data-line-end="14"><strong>Mental health professionals</strong>
<ul>
<li class="has-line-data" data-line-start="11" data-line-end="12">Could help identify early warning signs of depression, anxiety, or distress.</li>
<li class="has-line-data" data-line-start="12" data-line-end="13">Could help researchers understand large-scale mental health trends.</li>
<li class="has-line-data" data-line-start="13" data-line-end="14">However, online language is not always honest and representative.</li>
</ul>
</li>
<li class="has-line-data" data-line-start="14" data-line-end="18"><strong>Internet user</strong>
<ul>
<li class="has-line-data" data-line-start="15" data-line-end="16">Early detection tools could encourage people to seek help.</li>
<li class="has-line-data" data-line-start="16" data-line-end="18">Awareness of mental health language patterns may reduce stigma.</li>
</ul>
</li>
</ul>
<h2 class="code-line" data-line-start=18 data-line-end=19 ><a id="Ethical_Legal_Societal_Implications_18"></a>Ethical, Legal, Societal Implications</h2>
<ul>
<li class="has-line-data" data-line-start="19" data-line-end="20">I dont think there is anything unethical about the data for this project, since people should be expecting what they posted online be viewed or even stored by other people. As well as the legal aspect of the project, there is nothing illegal either.</li>
</ul>

</body></html>
22 changes: 22 additions & 0 deletions mini-project/Hoa_Ly_Idea2.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Hoa Ly - DATA 400 Spring 2026
## Idea 2
Sentimental analysis of comments on Reddit
## Research question
**How can we predict a person's mental health based on what they say on the internet ?**
## Data
For this idea, I will be scraping data from Reddit.
## Model
I plan to use Twitter-roberta-based-sentiment model for the project.
## Implications for stakeholders
- **Mental health professionals**
- Could help identify early warning signs of depression, anxiety, or distress.
- Could help researchers understand large-scale mental health trends.
- However, online language is not always honest and representative.
- **Internet user**
- Early detection tools could encourage people to seek help.
- Awareness of mental health language patterns may reduce stigma.

## Ethical, Legal, Societal Implications
- I dont think there is anything unethical about the data for this project, since people should be expecting what they posted online be viewed or even stored by other people. As well as the legal aspect of the project, there is nothing illegal either.


225 changes: 225 additions & 0 deletions mini-project/presentation.Rmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,225 @@
---
title: "How does Social Media relate to Mental Health"
author: "Hoa Ly"
institute: "Dickinson College"
date: "`r Sys.Date()`"
output:
xaringan::moon_reader:
lib_dir: libs
nature:
highlightStyle: github
highlightLines: true
countIncrementalSlides: false
---

```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = FALSE, warning = FALSE, message = FALSE)

library(xaringanthemer)
library(tidyverse)
```
class:center, middle
#Research Question

Can social media behaviors predict mental health symptoms?

---
<style>
.custom-spacing {
line-height: 1.8;
}
</style>

<div class="custom-spacing">
#Data Overview

- This project use dataset from Kaggle.
- Dataset consists of:
- Age
- Gender
- Relationship status
- Occupation
- Social media behavior patterns
- Mental health self-report measures of 481 participants.

<div>
---
<style>
.custom-spacing {
line-height: 1.8;
}
</style>

<div class="custom-spacing">
#Target Variable

**Mental Health Score**

Average of:
- Depressed mood
- Worries
- Sleep issues
- Difficulty concentrating
- Interest fluctuation

**Higher score = worse symptoms**

<div>
---
#Modeling Approach

Data cleaning and processing

80/20 Train-Test split

5-fold cross validation

**Model used:**

1.Multiple Linear Regression

2.Random Forest Regressor

**Evaluation metrics:**
- R^2

- MAE

- RMSE
---
#Model performance

**Multiple Linear Regression**

- Test R^2: 0.402

- MAE: 0.647

- RMSE: 0.794

- CV Mean R²: ~ 0.33

**Random Forest Regression**

- Test R²: 0.405

- MAE: 0.643

- RMSE: 0.792

- CV Mean R²: ~ 0.378

---
#Most important predictors
```{r dev='svg'}
importance_data <- tibble(
feature = c(
"Age",
"Distracted by Social Media",
"Social Comparison",
"Restless Without Social Media",
"Validation Seeking"
),
importance = c(0.195, 0.177, 0.144, 0.098, 0.056)
)

importance_data <- importance_data %>%
mutate(feature = fct_reorder(feature, importance))

ggplot(importance_data, aes(x = importance, y = feature)) +
geom_col() +
labs(
x = "Feature Importance (Random Forest)",
y = NULL,
title = "Top Predictors of Mental Health Score"
) +
theme_minimal(base_size = 20) +
theme(
plot.title = element_text(size = 16),
axis.title.x = element_text(size = 14)
)
```
---
#Key Findings
<style>
.custom-spacing {
line-height: 1.8;
}
</style>

<div class="custom-spacing">

<div style="font-size: 35px;font-weight: bold;text-align: center;">
"HOW social media is used matters more than HOW MUCH it is used."
</div>

- Compulsive use patterns are strong predictors

- Social comparison strongly associated with worse outcomes

- Platform choice was not among strongest predictors
<div>
---
#Interpratation
<style>
.custom-spacing {
line-height: 1.8;
}
</style>

<div class="custom-spacing">
Worse mental health scores are associated with:

- Using social media in a distracting way

- Frequently comparing oneself to others

- Seeking validation through likes/comments

- Feeling restless without checking apps

Time spent alone was not the strongest driver.
<div>
---
#Implications for Stakeholders

<style>
.custom-spacing {
line-height: 1.8;
}
</style>

<div class="custom-spacing">
**Students**

- Focus on reducing comparison and validation cycles

**Universities**

- Promote digital well-being education

**Social Media Platforms**

- Reconsider design features that amplify comparison

**Mental Health Professionals**

- Ask about usage behaviors, not just screen time
<div>
---
#Conclusion


<style>
.custom-spacing {
line-height: 1.8;
}
</style>

<div class="custom-spacing">
- Social media behaviors moderately predict mental health symptoms

- Behavioral patterns matter more than platform choice

- Compulsive and comparison-driven usage show strongest associations
<div>
Loading