Predictors of mental health literacy among adolescents using a random forest model: a machine learning approach
DOI:
https://doi.org/10.63719/imrj.2026.12.01.008Abstract
Mental health literacy (MHL) plays a critical role in early identification and help-seeking for mental disorders, especially among adolescents, a group facing a rising burden of depression and psychological distress globally. Traditional statistical approaches may overlook complex interactions among predictors. This study aimed to identify key predictors of MHL using a machine learning-based approach, specifically the Random Forest Model (RFM). A cross-sectional dataset comprising 1707 Malaysian adolescents with complete responses on 10 sociodemographic and psychosocial variables was analysed. MHL was dichotomised into Adequate and Inadequate categories. The dataset was split into training (80%) and testing (20%) subsets. Model development, hyperparameter tuning, and performance evaluation were conducted using R statistical software, with 5-fold cross-validation repeated three times. The final model was assessed on the test dataset using accuracy, sensitivity, specificity, Positive Predictive Value (PPV), Negative Predictive Value (NPV), F1 score, and Area Under the Curve (AUC). The final RFM, configured with 100 trees (mtry = 4, min.node.size = 1), achieved an AUC of 0.943 on the test dataset. The model achieved an accuracy of 87.1%, sensitivity of 90.0%, specificity of 87.0%, PPV of 17.0%, and F1 score of 0.29. Age emerged as the most important predictor, followed by Parental supervision and alcohol consumption. The RFM demonstrated high overall discrimination in classifying MHL levels. However, the relatively low precision suggests limited accuracy in identifying true positive cases, likely due to class imbalance, and findings should therefore be interpreted cautiously.
References
World Health Organization. Adolescent Mental Health [Internet]. Geneva: WHO; 2021 [cited 2025 Aug 3]. Available from: https://www.who.int/news-room/fact-sheets/detail/adolescent-mental-health.
Kieling C, Baker-Henningham H, Belfer M, Conti G, Ertem I, Omigbodun O, et al. Child and adolescent mental health worldwide: Evidence for action. Lancet. 2011;378(9801):1515–25. doi:10.1016/S0140‑6736(11)60827‑1.
Bor W, Dean AJ, Najman J, Hayatbakhsh R. Are child and adolescent mental health problems increasing in the 21st century? Aust N Z J Psychiatry. 2014;48(7):606–16. doi:10.1177/0004867414533834.
Twenge JM, Cooper AB, Joiner TE, Duffy ME, Binau SG. Age, period, and cohort trends in mood disorder indicators and suicide-related outcomes in a nationally representative dataset, 2005–2017. J Abnorm Psychol. 2019;128(3):185–99. doi:10.1037/abn0000410.
Jorm AF, Korten AE, Jacomb PA, Christensen H, Rodgers B, Pollitt P. “Mental health literacy”: A survey of the public’s ability to recognise mental disorders and their beliefs about the effectiveness of treatment. Med J Aust. 1997;166(4):182–6. doi:10.5694/j.1326‑5377.1997.tb140071.x.
Wei Y, McGrath PJ, Hayden J, Kutcher S. Mental health literacy measures evaluating knowledge, attitudes and help‑seeking: A scoping review. BMC Psychiatry. 2015;15:291. doi:10.1186/s12888‑015‑0681‑9.
O’Connor M, Casey L, Clough B. Measuring mental health literacy – A review of scale‑based measures. J Ment Health. 2014;23(4):197–204. doi:10.3109/09638237.2014.910646.
Steyerberg EW. Clinical Prediction Models. 2nd ed. New York: Springer Cham; 2019.
Shatte ABR, Hutchinson DM, Teague SJ. Machine learning in mental health: a scoping review of methods and applications. Psychol Med. 2019;49(9):1426–48. doi:10.1017/S0033291719000151.
Graham S, Depp C, Lee EE, Nebeker C, Tu X, Kim HC, Jeste DV. Artificial Intelligence for Mental Health and Mental Illnesses: an Overview. Curr Psychiatry Rep. 2019 Nov;21(11):116. doi:10.1007/s11920-019-1094-0.
Chekroud AM, Zotti RJ, Shehzad Z, Gueorguieva R, Johnson MK, Trivedi MH, Cannon TD, Krystal JH, Corlett PR. Cross-trial prediction of treatment outcome in depression: a machine learning approach. Lancet Psychiatry. 2016 Mar 1;3(3):243-50. doi:10.1016/S2215-0366(15)00471-X.
.
Breiman L. Random Forests. Mach Learn. 2001;45(1):5–32. doi: 10.1023/A:1010933404324.
Kuhn M, Johnson K. Applied Predictive Modeling. New York: Springer; 2013. doi:10.1007/978-1-4614-6849-3.
World Health Organization. Global School-Based Student Health Survey (GSHS) [Internet]. Geneva: World Health Organization; [cited 2026 Mar 27]. Available from: https://www.who.int/teams/noncommunicable-diseases/surveillance/systems-tools/global-school-based-student-health-survey.
Singh S, Zaki RA, Farid ND, Kaur K. The Determinants of Mental Health Literacy among Young Adolescents in Malaysia. Int J Environ Res Public Health. 2022 Mar 9;19(6):3242. doi:10.3390/ijerph19063242.
Yap MBH, Pilkington PD, Ryan SM, Jorm AF. Parental factors associated with depression and anxiety in young people: a systematic review and meta‑analysis. J Affect Disord. 2014;156:8–23. doi:10.1016/j.jad.2013.11.007.
Wang MT, Sheikh‑Khalil S. Does parental involvement matter for student achievement and mental health in high school? Child Dev. 2014;85(2):610–25. doi:10.1111/cdev.12153.
Loades ME, Chatburn E, Higson‑Sweeney N, Reynolds S, Shafran R, Brigden A, et al. Rapid systematic review: The impact of social isolation and loneliness on the mental health of children and adolescents in the context of COVID‑19. J Am Acad Child Adolesc Psychiatry. 2020;59(11):1218–39.e3. doi:10.1016/j.jaac.2020.05.009.
Qualter P, Brown SL, Munn P, Rotenberg KJ. Childhood loneliness as a predictor of adolescent depressive symptoms: An 8‑year longitudinal study. Eur Child Adolesc Psychiatry. 2010;19(6):493–501. doi:10.1007/s00787‑009‑0059‑y.
Arseneault L. The long‑term impact of bullying victimization on mental health. World Psychiatry. 2017;16(1):27–8. doi:10.1002/wps.20399.
Sawyer SM, Azzopardi PS, Wickremarathne D, Patton GC. The age of adolescence. Lancet Child Adolesc Health. 2018;2(3):223–228. doi:10.1016/S2352-4642(18)30022-1.
Cranford JA, Eisenberg D, Serras AM. Substance use behaviors, mental health problems, and use of mental health services in a probability sample of college students. Addict Behav. 2009;34(2):134-45. doi: 10.1016/j.addbeh.2008.09.004.
Paakkari L, Okan O. Health literacy—Talking the Language of (School) Education. Health Lit Res Pract. 2019;3(3):e161-4. doi: 10.3928/24748307-20190502-01.
Jorm AF. Mental health literacy: empowering the community to take action for better mental health. Am Psychol. 2012;67(3):231–243. doi:10.1037/a0025957.


