Analyzing Students' Mental Health in SQL
Does going to university in a different country affect your mental health? A Japanese international university surveyed its students in 2018 and published a study the following year that was approved by several ethical and regulatory boards.
The study found that international students have a higher risk of mental health difficulties than the general population, and that social connectedness (belonging to a social group) and acculturative stress (stress associated with joining a new culture) are predictive of depression.
Here is a data description of the columns you may find helpful.
| Field Name | Description |
|---|---|
inter_dom | Types of students (international or domestic) |
japanese_cate | Japanese language proficiency |
english_cate | English language proficiency |
academic | Current academic level (undergraduate or graduate) |
age | Current age of student |
stay | Current length of stay in years |
todep | Total score of depression (PHQ-9 test) |
tosc | Total score of social connectedness (SCS test) |
toas | Total score of acculturative stress (ASISS test) |
1 hidden cell
SELECT
stay,
COUNT(inter_dom) AS count_int,
ROUND(AVG(todep),2) AS average_phq,
ROUND(AVG(tosc),2) AS average_scs,
ROUND(AVG(toas),2) AS average_as
FROM students
WHERE inter_dom = 'Inter'
GROUP BY stay
ORDER BY stay DESC;SELECT
stay,
COUNT(inter_dom) AS count_int,
ROUND(AVG(todep),2) AS average_phq,
ROUND(AVG(tosc),2) AS average_scs,
ROUND(AVG(toas),2) AS average_as
FROM students
WHERE inter_dom = 'Inter'
GROUP BY stay
ORDER BY stay DESC;
Results and Charts
PHQ - Depression
The results show that there is a downward trend in depression scores for a stay up to 5 years. After 5 years the longer international students stay in Japan, the higher their scores are for depression.
AVG score of depression (PHQ-9 test)
SCS - Social Connectedness
AVG score of social connectedness (SCS test)
ASISS test - Stress
Stress trends upwards in the first 5 years of a student's stay, likely because they are actively in school and trying to adapt to a new enviornment, culture, and language while mainting their school work. After year 5, stress begins to trend downwards as students are likely becoming more familiar with their enviornment. There is likely a correlation between social connectendess and stress as they trend very similarly, when social connenctedness is high, stress tends to be low and vice versa.
Challenges in the Data
- The amount of international students lowers significantly as the stay in years becomes longer.
- The majority of students stay less than 5 years
-- COUNT OF ALL RECORDS = 286 SELECT COUNT(*) AS total_records FROM 'students.csv';
-- 201 records are inter, 67 are Dom, 18 null SELECT * FROM students.csv WHERE inter_dom = 'Inter'
-- all students summary statistics SELECT ROUND(MIN(todep),2) AS min_phq, ROUND(MAX(todep),2) AS max_phq, ROUND(AVG(todep),2) AS avg_phq, ROUND(MIN(tosc),2) AS min_scs, ROUND(MAX(tosc),2) AS max_scs, ROUND(AVG(tosc),2) AS avg_scs, ROUND(MIN(toas),2) AS min_asiss, ROUND(MAX(toas),2) AS max_asiss, ROUND(AVG(toas),2) AS avg_asiss FROM students
min_phq = 0 max_phq = 25 avg_phq = 8.19 min_scs = 8 max_scs = 48 avg_scs = 37.47 min_asiss = 36 max_asiss = 145 avg_asiss = 72.38
-- international students summary statistics SELECT ROUND(MIN(todep),2) AS min_phq, ROUND(MAX(todep),2) AS max_phq, ROUND(AVG(todep),2) AS avg_phq, ROUND(MIN(tosc),2) AS min_scs, ROUND(MAX(tosc),2) AS max_scs, ROUND(AVG(tosc),2) AS avg_scs, ROUND(MIN(toas),2) AS min_asiss, ROUND(MAX(toas),2) AS max_asiss, ROUND(AVG(toas),2) AS avg_asiss FROM students WHERE inter_dom = 'Inter'
min_phq = 0 max_phq = 25 avg_phq = 8.04 min_scs = 11 max_scs = 48 avg_scs = 37.42 min_asiss = 36 max_asiss = 145 avg_asiss = 75.56
SELECT stay, ROUND(AVG(todep),2) AS avg_phq, ROUND(AVG(tosc),2) AS avg_scs, ROUND(AVG(toas),2) AS avg_as FROM students WHERE inter_dom = 'Inter' GROUP BY stay ORDER BY stay DESC;
The results show that the longer international students stay in Japan, the higher their scores are for depression and stress. Social connectedness starts out higher then lowers, it starts to raise again after 5 years but drops sharply at 10 years, likely due to no longer being in school and the struggle of finding a community in a mostly homogenous state.