Psychological Resilience in Youth: A Machine Learning Analysis of Protective Factors and Stress Exposure

Authors

    Rafael Costa Department of Educational Psychology, Federal University of Rio de Janeiro, Rio de Janeiro, Brazil
    Nomvula Dlamini * Department of Psychology, University of Cape Town, Cape Town, South Africa nomvula.dlamini@uct.ac.za
https://doi.org/10.61838/kman.jayps.4907

Keywords:

psychological resilience, youth mental health, cumulative stress, protective factors, machine learning, South Africa

Abstract

Objective: This study aimed to identify and model the relative and interactive contributions of protective factors and cumulative stress exposure in predicting psychological resilience among youth using machine learning techniques.

Methods and Materials: A cross-sectional study was conducted with a diverse sample of adolescents and emerging adults from urban and peri-urban regions of South Africa. Participants completed validated self-report measures assessing psychological resilience, cumulative stress exposure, and a range of individual and contextual protective factors, including emotion regulation, self-efficacy, optimism, family support, peer support, and school belonging. Data were analyzed using supervised machine learning algorithms, including regularized linear models, support vector machines, random forest, and gradient boosting machines. Model performance was evaluated using repeated cross-validation procedures, and feature importance and interaction effects were examined through permutation-based methods and partial dependence analyses.

Findings: Inferential analyses indicated that ensemble machine learning models significantly outperformed linear approaches in predicting psychological resilience. The gradient boosting model explained a substantial proportion of variance in resilience scores and demonstrated high classification accuracy for distinguishing low, moderate, and high resilience profiles. Family support, emotion regulation, and self-efficacy emerged as the strongest predictors of resilience. Interaction analyses revealed that the protective effects of key resources intensified under higher levels of cumulative stress exposure, indicating robust stress-buffering effects.

Conclusion: The findings demonstrate that youth psychological resilience is best understood as a multidimensional and non-linear outcome shaped by dynamic interactions between stress exposure and protective factors. Machine learning approaches provide valuable tools for advancing resilience research by capturing complex patterns and identifying high-impact protective resources. These results underscore the importance of strengthening relational and emotional capacities to promote resilience among youth facing adversity.

Downloads

Download data is not yet available.

References

Boyd, D. T., Jones, K., Quinn, C. R., Gale, A., Williams, E. D. G., & Lateef, H. (2022). The Mental Health of Black Youth Affected by Community Violence: Family and School Context as Pathways to Resilience. Children, 9(2), 259. https://doi.org/10.3390/children9020259

Carrier, L., Shin, H. D., Rothfus, M., & Curran, J. (2022). Protective and Resilience Factors to Promote Mental Health Among Indigenous Youth in Canada: A Scoping Review Protocol. BMJ open, 12(1), e049285. https://doi.org/10.1136/bmjopen-2021-049285

Caruso, A. J., Basu, A., Urban, T. H., Kaskas, M. M., Rotter, N., Wozniak, J., & Friedman, D. S. (2024). Assessing Service Usage and Protective Factors in a Pediatric Psychiatry Clinic During the COVID-19 Pandemic. Frontiers in psychology, 15. https://doi.org/10.3389/fpsyg.2024.1354544

Chen, S. Y., Yan, S.-R., Zhao, W., Gao, Y., Zong, W., Bian, C., Cheng, Y., & Zhang, Y. (2022). The Mediating and Moderating Role of Psychological Resilience Between Occupational Stress and Mental Health of Psychiatric Nurses: A Multicenter Cross-Sectional Study. BMC psychiatry, 22(1). https://doi.org/10.1186/s12888-022-04485-y

Cheong, Y., Zhu, Q., Wang, C., He, M., & Ye, Y. (2022). COVID-19 Stressful Life Events and Chinese Adolescents’ Mental Health: Examining Resilience, Peer Relationship, and Parenting as Moderators. The Journal of Early Adolescence, 43(5), 577-602. https://doi.org/10.1177/02724316221114091

Giridharan, S., & Pandiyan, B. (2024). A Path to Resilience: The Impact of School-Based Yoga on Adolescent Mental Well-Being. Cureus. https://doi.org/10.7759/cureus.73604

Huang, C., Xie, J., Owusua, T., Chen, Z., Wang, J., Qin, C., & He, Q. (2021). Is Psychological Flexibility a Mediator Between Perceived Stress and General Anxiety or Depression Among Suspected Patients of the 2019 Coronavirus Disease (COVID-19)? Personality and individual differences, 183, 111132. https://doi.org/10.1016/j.paid.2021.111132

Jia, T. (2025). A Psychobiological Resilience Factor for Mental Health Across the Lifespan. https://doi.org/10.21203/rs.3.rs-7861905/v1

Jones, E. A., Mitra, A. K., & Bhuiyan, A. R. (2021). Impact of COVID-19 on Mental Health in Adolescents: A Systematic Review. International journal of environmental research and public health, 18(5), 2470. https://doi.org/10.3390/ijerph18052470

Khunti, K., Boniface, S., Norris, E., Oliveira, C. d., & Shelton, N. (2022). The Effects of Yoga on Mental Health in School-Aged Children: A Systematic Review and Narrative Synthesis of Randomised Control Trials. Clinical Child Psychology and Psychiatry, 28(3), 1217-1238. https://doi.org/10.1177/13591045221136016

Koper, N., Creemers, H. E., Dam, L. v., Geert Jan, J. M. S., & Branje, S. (2022). Resilience, Well-Being and Informal and Formal Support in Multi-Problem Families During the Covid-19 Pandemic. Child and adolescent psychiatry and mental health, 16(1). https://doi.org/10.1186/s13034-022-00542-2

Kuhlman, K. R., Straka, K., Mousavi, Z., Tran, M.-L., & Rodgers, E. (2021). Predictors of Adolescent Resilience During the COVID-19 Pandemic: Cognitive Reappraisal and Humor. Journal of Adolescent Health, 69(5), 729-736. https://doi.org/10.1016/j.jadohealth.2021.07.006

Kurudirek, F., Arıkan, D., & Ekici, S. (2022). Relationship Between Adolescents’ Perceptions of Social Support and Their Psychological Well-Being During COVID-19 Pandemic: A Case Study From Turkey. Children and Youth Services Review, 137, 106491. https://doi.org/10.1016/j.childyouth.2022.106491

Lei, W., Hu, W., Hong-xia, G., & Dai, D. Y. (2024). Does Growth Mindset Benefit Negative Mental Health Among Middle School Students: The Role of Psychological Resilience and Gender. Psychology in the Schools, 61(9), 3497-3513. https://doi.org/10.1002/pits.23227

López, M. O., & Gómez‐Baya, D. (2025). Interventions to Promote Civic Engagement Among Youth and Its Outcomes on Mental Health: A Scoping Review. Children, 12(6), 665. https://doi.org/10.3390/children12060665

Mulligan, C. J., Clukay, C. J., Matarazzo, A., Hadfield, K., Nevell, L., Dajani, R., & Panter‐Brick, C. (2022). Novel GxE Effects and Resilience: A Case:control Longitudinal Study of Psychosocial Stress With War-Affected Youth. PLoS One, 17(4), e0266509. https://doi.org/10.1371/journal.pone.0266509

Nilsson, D., Svedin, C. G., Lundqvist, C., & Dahlström, Ö. (2023). Resilience in Swedish Adolescents—Does Resilience Moderate the Relationship Between Trauma Experience and Trauma Symptoms? Psychological Trauma Theory Research Practice and Policy, 15(Suppl 1), S125-S134. https://doi.org/10.1037/tra0001338

Noyola, N., Pault, M. V., Hirshfeld‐Becker, D. R., Chudnofsky, R., Meek, J., Wells, L. N., Wilens, T. E., & Henin, A. (2024). The Resilient Youth Program: A Promising Skills-Based Online Program for Resiliency and Stress Management. Behavioural and Cognitive Psychotherapy, 52(3), 331-335. https://doi.org/10.1017/s1352465823000644

Pandey, S., Saxena, S., Joshi, P. C., & Mahajan, C. (2023). Perceived Stress, Anxiety and Depression : Living Along the Border in Jammu and Kashmir. International Journal of Social Psychiatry, 69(6), 1532-1540. https://doi.org/10.1177/00207640231168032

Rohner, S. L., Bernays, F., Maercker, A. r. a., & Thoma, M. V. (2023). Early-Life Adversity and Later-Life Mental Health: A Conditional Process Analysis of Sense of Coherence and Resilience-Related Resources. Frontiers in Child and Adolescent Psychiatry, 2. https://doi.org/10.3389/frcha.2023.1213142

Rosen, M. L., Rodman, A. M., Kasparek, S. W., Mayes, M., Freeman, M. M., Lengua, L. J., Meltzoff, A. N., & McLaughlin, K. A. (2021). Promoting Youth Mental Health During the COVID-19 Pandemic: A Longitudinal Study. PLoS One, 16(8), e0255294. https://doi.org/10.1371/journal.pone.0255294

Ruíz‐Párraga, G. T., Serrano‐Ibáñez, E. R., Gómez‐Pérez, L., Ramírez‐Maestre, C., Esteve, R., & López‐Martínez, A. E. (2021). The Relevance of Psychological Strength for Physical and Psychological Well‐being in Trauma‐exposed Women. Scandinavian journal of psychology, 62(3), 386-392. https://doi.org/10.1111/sjop.12711

Russell, D. W., Russell, C. A., Chen, H. Y., Cacioppo, S., & Cacioppo, J. T. (2021). To What Extent Is Psychological Resilience Protective or Ameliorative: Exploring the Effects of Deployment on the Mental Health of Combat Medics. Psychological Services, 18(1), 51-63. https://doi.org/10.1037/ser0000343

Shin, H. D., Carrier, L., Dame, J., Padley, M. A., Daclan, A., Wong, H., Dass, R., Dorey, R., Cameron, E. S., Langley, J., & Curran, J. (2024). Resilience and Protective Factors for Mental Health Among Indigenous Youth in Canada: A Scoping Review. https://doi.org/10.1101/2024.08.05.24311522

Shukla, M., Wu, A. F., Lavi, I., Riddleston, L., Hutchinson, T., & Lau, J. Y. F. (2022). A Network Analysis of Adolescent Mental Well-Being During the Coronavirus Pandemic: Evidence for Cross-Cultural Differences in Central Features. Personality and individual differences, 186, 111316. https://doi.org/10.1016/j.paid.2021.111316

Somefun, O. D., Theron, L., & Ungar, M. (2023). The Association Between Family Adversity and Youth Mental Health Outcomes. Journal of adolescence, 95(7), 1333-1347. https://doi.org/10.1002/jad.12205

Tindle, R., Hemi, A., & Moustafa, A. A. (2022). Social Support, Psychological Flexibility and Coping Mediate the Association Between COVID-19 Related Stress Exposure and Psychological Distress. Scientific reports, 12(1). https://doi.org/10.1038/s41598-022-12262-w

Veronese, G., Mahamid, F., & Bdier, D. (2025). Traumatic Grief, Health and Mental Health in Palestine: The Mediating Role of Posttraumatic Growth and Resilience. Health Psychology Report. https://doi.org/10.5114/hpr/199540

Wang, Y., Lu, T., Yan, X., Xu, H., & Liang, W. (2025). The Moderating Role of Adverse Childhood Experiences in the Relationship Between Disability and Depression in Old Age: Evidence From China. Psychiatry Investigation, 22(8), 930-938. https://doi.org/10.30773/pi.2024.0380

Zhang, Q., Dong, G., Meng, W., Chen, Z., Cao, Y., & Zhang, M. (2022). Perceived Stress and Psychological Impact Among Healthcare Workers at a Tertiaty Hospital in China During the COVID-19 Outbreak: The Moderating Role of Resilience and Social Support. Frontiers in Psychiatry, 12. https://doi.org/10.3389/fpsyt.2021.570971

Zhang, X., Brown, A., & Rhubart, D. (2023). Can Resilience Buffer the Effects of Loneliness on Mental Distress Among Working-Age Adults in the United States During the COVID-19 Pandemic? A Latent Moderated Structural Modeling Analysis. International Journal of Behavioral Medicine, 30(6), 790-800. https://doi.org/10.1007/s12529-022-10151-0

Additional Files

Published

2025-12-10

Submitted

2025-07-28

Revised

2025-11-10

Accepted

2025-11-10

How to Cite

Costa, R., & Dlamini, N. (2025). Psychological Resilience in Youth: A Machine Learning Analysis of Protective Factors and Stress Exposure. Journal of Adolescent and Youth Psychological Studies (JAYPS), 6(12), 1-11. https://doi.org/10.61838/kman.jayps.4907