Identifying The Most Important Workplace Factors in Predicting Mental Health Among British Columbia Nurses Using Machine Learning Techniques

Nurses are at a high risk of developing mental health problems due to exposure to work environment risk factors. Previous research in this area has only examined a few factors within nurses’ work environments, and those factors were not conceptualized with the goal of improving workplace mental health. The purpose of this study is to identify the most important work environment predictors of nurse mental health using a comprehensive and theoretically grounded measure based on the National Standard of Psychological Health and Safety in the Workplace. This is an exploratory cross-sectional survey study of nurses in British Columbia, Canada. For this study, responses from a convenience sample of 4,029 actively working direct care nurses were analyzed using random forest regression methods. Key predictors include 13 work environment factors. Study outcomes include depression, anxiety, post-traumatic stress disorder (PTSD), burnout and life satisfaction. research question: which of the Standard’s 13 mental


Introduction
Nurses and other healthcare providers are at a high risk of developing mental health problems due to signi cant exposure to workplace risk factors such as human suffering and death, inadequate sta ng, heavy workloads and workplace violence (1,2). Poor mental health in healthcare workers has been linked to sub-optimal performance (3), negative patient safety outcomes (4), staff absenteeism (3) and turnover (5). Existing research has found that workplace conditions such as workload management, sta ng and resource adequacy are among the most important determinants of nurse mental health; however, this body of evidence is limited in that it has only examined a few factors within nurses' work environments and those factors were not conceptualized with the goal of improving workplace mental health (6-8).
The purpose of this study is to identify the most important workplace conditions predicting the mental health of nurses, the largest health human resource worldwide, using a theoretically sound and comprehensive measure of work environment conditions that was developed with the intent of optimizing workplace mental health based on the National Standard for Workplace Psychological Health and Safety" (i.e., the Standard) (9,10). Given the expected shortage of the nursing workforce in Canada and internationally (11,12), this research is both timely and important as it helps identify and address aspects of the workplace associated with nurses' mental health-an important dimension of nurse job satisfaction and retention (13).

Literature Review
Literature Review

Mental Health
The World Health Organization de nes mental health as "a state of well-being in which an individual realizes his or her own abilities, can cope with the normal stresses of life, can work productively and is able to make a contribution to his or her community" (14). Thus, mental health can be operationalized through the presence or absence of a general positive state or mental health disorders such as depression, anxiety, Post Traumatic Stress Disorder (PTSD) and burnout. The prevalence of these mental health problems has been found to range between 10% (PTSD) and 41% (anxiety) among different groups of nurses worldwide (15). In Canada, a national pre-pandemic survey showed that 20% of 7,358 participating nurses met the criteria for PTSD and general anxiety disorder; and one third met the criteria for major depressive disorder (1). Compared to the national nursing workforce, the mental health of British Columbia (BC) nurses is even more concerning; using pre-pandemic data, a 2021 study showed the prevalence of mental health problems as 1.5 to 3 times higher among BC nurses compared to their peers nationally (15).

Work Environment In uences
Work environment conditions play a major role in in uencing nurses' mental health (6,(16)(17)(18)(19)(20). The nursing work environment literature can be classi ed into three distinct bodies of evidence: (a) structural empowerment (21)(22)(23), (b) magnet hospitals (6, 24), and (c) the areas of worklife (7,8,25). Building on Kanter's theory of power within organizations, Laschinger et al. developed the notion of work environment structural empowerment (26). Measured by the Conditions of Work Environment Questionnaire II (CWEQ-II), structural empowerment refers to nurses' perceptions of access to six empowering work environment structures including information, resources, opportunities, supports and formal and informal channels of power (27). Another body of literature focuses on the concept of magnet hospital, which originated in the early 1980s during a severe nursing shortage in the United States. Some hospitals, known as "magnet hospitals," had certain characteristics associated with better nurse recruitment and retention than nonmagnet hospitals (6, 24). Building on this initial research, Lake identi ed ve attributes of magnet hospitals: leadership, collegial nurse-physician relations, opportunities for nurse participation, adequacy of sta ng and resources as well as a nursing (rather than a biomedical) model of care. These attributes can be measured by the Practice Environment Scale from the Nursing Work Index (PES-NWI) (6, 24). The third body of work environment evidence, the Areas of Worklife Model, originated from the work of Maslach and Leiter on nursing burnout (7,8) According to this body of evidence, a mismatch between individual nurses and six aspects of their work environment is the main antecedent of burnout.
Operationalized by the Areas of Worklife Survey (AWS), these work environment aspects include workload, control, reward, community, fairness and values (7,28). Despite their impact on nurse mental health and wellbeing, these conceptualizations of work environment conditions were not developed with the goal of protecting nurses' mental health in the workplace.
The Mental Health Commission of Canada developed the Standard which is comprised of a set of guidelines, tools and resources aimed at promoting employee health and preventing mental health injury in the workplace (9,10). While the Standard is not speci c to nurses or the healthcare sector, it has been developed with the goal of improving worker mental health (9,10).
In recognition of the rising mental injury among nurses and other healthcare providers, in 2016, the British Columbia Nurses Union (BCNU) became the rst and only union in Canada to bargain for implementation of The Standard within the province's health authorities (29). As a result of this bargaining effort, BC health authorities are mandated to protect the mental health of their nursing workers and other healthcare providers in the workplace via the implementation of the Standard.
The implementation of the Standard begins with a comprehensive, baseline assessment of work environment conditions most important to employee mental health. Founded upon empirical and theoretical evidence, these conditions were systematically identi ed using a grounded theory approach which involved a comprehensive literature review and consultation with subject matter experts with the intent of optimizing mental health in the workplace (9,30). A 13-factor measure, the Guarding Minds at Work (GMW) Survey, was developed to measure workplace conditions important to employee mental health. The GMW was recently validated among 3,077 direct care nurses working in acute care settings in BC (29). This study found that pre-pandemic over half of the nurse respondents were concerned about nine of the 13 workplace factors assessed using the GMW survey (29). The current study examines one key research question: which of the Standard's 13 workplace conditions most strongly predict nurses' mental health?

Methods
This study is a partnership between nurse researchers and the BCNU representing nearly 48,000 nurses in the province using a cross-sectional correlational survey design. The BCNU sent an email invite with the survey link to its nurse members asking them to complete the study survey. Participants were informed of the voluntary nature of their participation; the con dentiality of their responses and that survey submission would indicate informed consent. To increase response rate, a series of strategies were used including a two-month data collection period, weekly reminders, survey advertisement on multiple platforms and a ra e draw for two Apple Watches. In total, 5512 surveys were returned resulting in an estimated 12% response rate. For this study, only actively working direct care nurses were included yielding a nal sample size of 4,029 participants. Ethics approval was obtained from the University Behavioral Research Ethics Board (approval number: H18-02724). items) and Personal Accomplishment (PA, eight items). Additionally, a single life satisfaction indicator, adopted from Statistics Canada (2013), asked participants to rate the extent to which they were satis ed or dissatis ed with their life as a whole with response options ranging from very dissatis ed (0) to very satis ed (10). Guided by previous research, all mental health outcomes were converted into composite factor scores (centered around the mean) using Con rmatory Factor Analysis (CFA) (31,32). An exception was the life satisfaction (uncentered) measure that was single variable index.

Measures
Predictors. The conditions of nurses' work environments were measured using the GMW survey consisting of 65 items and 13 factors (Table 1). Each factor consists of ve statements about a speci c workplace condition, and participants are asked to indicate their level of agreement or disagreement with each statement on a four-point scale ranging from strongly disagree (1) to strongly agree (4). The internal structure of the measure was previously evaluated among BC nurses and yielded a 13-factor structure (29). In this study, because we are interested in the predictive power of each work environment factor, composite factor scores were obtained using CFA (31,32) with higher factor scores indicating healthier workplace conditions. Controls. A set of demographic variables such as age, gender (female, male), years of nursing experience, healthcare sector (acute, care, community care, long-term care) and geographical region (urban, suburban, rural) were included as control variables in this study. Healthcare sector and geographic region were dummy-coded as follows: (Healthcare sector, sec1: acute care=1, long-term care=0; sec2: community care = 1, long-term care =0; Geographical region, reg1: urban = 1, rural=0; suburban =1, rural=0).

Data Analysis
The internal consistencies for all the composite predictors and outcomes were evaluated using a coe cient ω >.8 as an indication of good internal consistency and a coe cient ω between .7 and .8 as an indication of acceptable internal consistency (33,34). The internal structure of the multi-item mental health outcomes was evaluated using a CFA approach with the following indices used to evaluate model t: Comparative Fit Index (CFI ≥ 0.90), Tucker Lewis Index (TLI≥ 0.95) and Standardized Root Mean Squared Residual (SRMR < 0.08) (35). The internal structure of the GMW scale was recently evaluated using data from BC nurses in different study and therefore not included in the current study (29) Data were further analyzed using random forest (RF) analysis, a supervised machine learning algorithm (36), that nonlinearly regressed each of the seven mental health outcomes on all of the 13 GMW factors after taking into account the impact of control variables including age, years of experience, healthcare sector and geographical region. As is the case with other RF studies (37), a 10-fold cross-validation was applied, and for each fold, a 70% and 30% dataset were respectively used as a training and testing set. The training and testing sets were then used to evaluate the model performance through the Root Mean Square Error (RMSE). A higher RMSE for the testing set compared to the training set would indicate lack of over t and the appropriate use of this RF for prediction purposes. The "importance score" of the predictors was gauged by the average level of the decline in prediction accuracy after a speci c predictor was excluded. A greater decline in prediction accuracy would indicate that the excluded predictor is highly ranked in terms of importance (38). In addition, the R-squared was used to identify the proportion of the variance in each outcome variable explained by the model predictors. Finally, partial correlation was used to determine the direction of the association between outcomes and predictors while taking control variables into account. The R package "caret" was used for data analysis (38).

Results
A majority of our sample were female (n = 3,676, 91%) with an average age of 40 years old (SD = 12 years) and 12 years of nursing experience (SD = 7 years). Over two-thirds of the sample worked in acute care sector (76%), compared to community (16%) and long-term care (7%) sectors, and in urban settings (68%), compared to suburban (18%) and rural (19%) areas. Table 1 provides descriptive statistics as well as reliability indices for key predictors and outcomes. Table 2 presents the model t indices for the six composite mental health outcomes. McDonald' ω ranged between .74 to .93 indicating good internal consistency for 11 workplace factors and ve mental health outcomes but acceptable internal consistency for two workplace factors (i.e., "job t" and "growth development") and one burnout indicator (i.e., personal accomplishment) ( Table 1). The t indices supported a good model t for ve of the mental health outcomes and an acceptable t for one of these outcomes (i.e. PTSD) ( Table 2). Table 3 shows the results of the RF analysis identifying the relative ranking of the 13 workplace conditions predicting nurse's mental health. Overall, the model accounted for 18-37% of the variance across seven mental health outcomes. For all of the seven model, the RMSE for the test data set was greater than the train dataset, suggesting lack of over t and appropriateness for prediction purposes.
More speci cally, balance (importance score: 28.80 to 43.28), psychological protection (importance score: 21.15 to 30.41) and workload management (importance score: 20.30 to 57.17) were the most important predictors of depression, anxiety, PTSD and emotional exhaustion. Furthermore, while engagement (importance score: 29.62), workload management (importance score: 26.21), psychological protection (importance score: 20.57) and balance (importance score: 20.45) were the most important predictors of depersonalization, engagement (importance score: 44.16) was the most important predictor of personal accomplishment. Balance (importance score: 38.11), psychological protection (importance score: 25.91) and engagement (importance score: 24.99) were the most important predictors of life satisfaction. Additionally, the direction of associations between predictors and each outcome was examined. All predictors were negatively associated with negative mental health outcomes, and positively related to positive mental health outcomes. To be more speci c, nurses' reports of healthier workplace conditions predicted lower scores on depression, anxiety, PTSD and emotional exhaustion as well as higher scores on personal accomplishment and life satisfaction.

Discussion
To our knowledge, this is the rst study to evaluate the work environment conditions predicting nurse mental health using the comprehensive and theoretically founded GMW. Our ndings showed adequate worklife balance, psychological protection and workload management are the most important work environment conditions in uencing nurse mental health. Worklife balance refers to work environments where employees have the exibility and the autonomy to manage the demands of their professional and personal lives (30). Worklife balance is not a component of the structural empowerment or magnet hospital bodies of evidence, but it is a component of the Area of Worklife Model's control domain. When employees have greater control over work decisions, such as maintenance of worklife balance, they are less likely to report adverse mental health outcomes, including burnout (7, 28). Of note is that previous research with younger generations of nurses identi ed that worklife balance is what they value most in their work environments (39) Psychological protection represents work environments where employees' psychological safety is 'protected' by preventing unnecessary stress, such as exposure to workplace violence and discrimination (30). Although absent from the major models of nursing work environment, workplace violence literature has linked various types (e.g. physical, emotional) and sources (e.g. patients, co-workers) of workplace violence to poor nurse mental health (40,41). This nding is especially relevant with rising rates of workplace violence in healthcare (42).
Workload management re ects a work environment where assigned tasks and resources can be accomplished successfully within the time available (30). This GMW factor is present within all three nursing work environment bodies of evidence where it is a known determinant of nurse and patient outcomes. In structural empowerment theory, workload management is represented by employees' access to resources and supports in the workplace (21,22). The magnet hospital model conceptualizes the adequacy of sta ng and resources as an indicator of workload management (6), and the Area of Worklife Model includes a workload dimension and describes it as working conditions where employee demands exceed their limits (7,28).
In addition to these work environment conditions, engagement was an important predictor of nurse mental health outcomes, particularly personal accomplishment and life satisfaction. According to the GMW model, engagement re ects a work environment where employees have a sense of connection and commitment to their colleagues and the organization (30). While this factor is conceptualized as an employee's sense of community in the Areas of Worklife Model (28), it is not included in the structural empowerment and magnet hospital models of work environment. Consistent with our study, previous research has linked a greater sense of community and engagement to better nurse outcomes, including personal accomplishment (43) In additional to enriching our theoretical understanding of healthy work environments, the study ndings have profound implications for policy and practice, particularly in the context of a stressful and unprecedent pandemic that has overburdened healthcare workers around the globe with rising prevalence of mental health problems (16). We found among all 13 GMW factors, worklife balance, psychological protection and workload management were the most important determinants of nurse mental health.
These ndings are especially important in light of a recent study describing BC nurses' work environment using the GMW; this study found almost 75% of respondents were more concerned with these work environment factors than other workplace conditions (29).
These ndings offer a direction for workplace strategies and interventions that best address current mental health needs of nurses. While worklife balance can be directly promoted through adopting certain strategies such as exible scheduling systems that allow self scheduling (44), we believe maintaining worklife balance is not possible without effective workload management. Previous research has taken a multidimensional approach to workload management where a variety of factors at the task level (e.g. interruptions when performing a task), work unit level (e.g. sta ng levels, patient acuity and dependency) and job level (e.g. missed breaks, undone tasks) in uence the magnitude of nurses' workloads (45,46). A systems approach, therefore, is helpful when considering workload management factors that in uence nurses' mental health (45,46).
Nurse sta ng is one of the most well studied indicators of workload at the unit level (45). A plethora of research evidence has linked inadequate sta ng levels and inappropriate skill mix (i.e., types of healthcare providers) with work overload that results in negative nurse and patient outcomes (47). While increasing the supply of professional nurses would be an important long-term goal, it is not an immediate intervention given the current shortage of nurses worldwide (47). Nurse leaders must work with their current nancial and human resources to enable better workload management. One of these interventions is evidence-based workload management tools that inform sta ng guidelines based on patient needs in real time (47). A systematic review has linked the use of such tools to better patient, organization and nurse outcomes including mental health (48).
Along with workload management, nurses are in need of work environments where their health and safety are protected. Workplace violence prevention strategies, including code white drills, enough security personnel, and employers that listen to staff's suggestions are associated with nurses' perceptions of increased workplace safety (49). Given the rising prevalence of workplace violence in healthcare (42), policy makers and leaders must work towards instituting these evidence-based policies and interventions.
These recommendations are based on empirical data gathered from nurses using the GMW. The GMW survey corresponds with the Canadian "National Standard of Psychological Health and Safety", the rst international standard to comprehensively promote psychological health and safety in the workplace.
This standard is accompanied with evidence-based resources and strategies to assist healthcare leaders with routine employee assessment and implementation of workplace interventions as needed (50).

Strengths And Limitations
This study used an innovative machine learning technique, RF analysis, to identify the relative importance of 13 different workplace conditions in predicting nurse mental health. While, RF methods do not offer any clinical signi cance information, compared to linear regression analysis, they are more appropriate for analyzing and evaluating the relative importance of large numbers of predictors (51). In such cases, RF models yield more stable results than conventional regression analyses (52). Furthermore, the work environment measure used in this study, the GMW survey, is a comprehensive and validated instrument developed with the goal of improving workplace mental health (29). Despite these strengths, the study also has some limitations including convenience sampling and low response rate which suggest the possibility of sampling bias. However, a descriptive comparison of our sample with the provincial nursing workforce demonstrated less than 10% difference with respect to nurse demographics including gender and professional designation (blinded for review). Despite this nding, the study results should be cautiously generalized to other samples and contexts. We also refrain readers from making any causeand-effect conclusions due to the cross-sectional nature of the study.

Conclusions
This is the rst study examining the most important work environment predictors of nurse mental health using a validated and comprehensive measure of workplace conditions developed by the Mental Health Commission of Canada. Policy and practice efforts to promote nurse mental health should be data driven through routine and con dential assessment of work environment conditions and nurse mental health.
This study suggested there is a critical need for addressing worklife balance, psychological protection and workload management in nurses' work environments.