The socio-spatial context as a risk factor for hospitalization due to mental illness in the metropolitan areas of Portugal

This study’s aims are: (i) identifying spatial patterns for the risk of hospitalization due to mental illness and for the potential risk resulting from contextual factors with influence on mental health; and (ii) analyzing the spatial association between risk of hospitalization due to mental illness and potential risk resulting from contextual factors in the metropolitan areas of Lisbon and Porto, Portugal. A cross-sectional ecological study was conducted by applying statistical methods for assessing spatial dependency and heterogeneity. Results reveal a spatial association between risk of hospitalization due to mental illness and potential risk resulting from contextual factors with a statistical relevance of moderate intensity. 20% of the population under study lives in areas with a simultaneously high potential risk resulting from contextual factors and risk of hospitalization due to mental illness. Porto Metropolitan Area show the highest percentage of population living in parishes with a significantly high risk of hospitalization due to mental health, which puts forward the need for interventions on territory-adjusted contextual factors influencing mental health. Mental Health; Mental Disorders; Social Determinants of Health; Urban Health Resumo Este estudo pretende: (i) identificar padrões espaciais do risco de internação por doença mental e do risco potencial resultante dos fatores do contexto com influência na saúde mental; e (ii) analisar a associação espacial entre o risco de internação por doença mental e o risco potencial resultante dos fatores do contexto, nas areas metropolitanas de Lisboa e Porto, Portugal. Foi conduzido um estudo ecológico transversal com a aplicação de métodos estatísticos de avaliação da dependência e heterogeneidade espacial. Os resultados revelam uma associação espacial entre o risco de internação por doença mental e o risco potencial resultante dos fatores do contexto com significância estatística e de intensidade moderada. Nas áreas, simultaneamente, de risco potencial resultante dos fatores do contexto e risco de internação por doença mental elevados, vivem 20% da população em estudo. Destacouse a Área Metropolitana do Porto com a maior porcentagem de população residindo em freguesias com risco de internação por doença mental significativamente alto, impondo a necessidade de intervenções sobre os fatores contextuais que influenciam a saúde mental, ajustadas aos territórios. Saúde Mental; Transtornos Mentais; Determinantes Sociais da Saúde; Saúde Urbana http://dx.doi.org/10.1590/0102-311X00090514 Loureiro A et al. S220 Cad. Saúde Pública, Rio de Janeiro, 31 Sup:S219-S231, 2015 Introduction Mental health is an essential component of one’s wellbeing 1; however, mental disorders are currently one of the main causes of impairment, and high rates or morbidity and mortality 2, particularly prematurely. Between 1990 and 2010, the weight of mental illness and substance abuserelated diseases increased 37.8% 3. Portugal is one of the European countries with the highest prevalence of mental disorders 4. There is growing scientific interest in the study of the relationship between context (considered as the setting of residence/work/teaching/leisure) and health, and also in the influence of context as a trigger of health inequalities. A number of authors have suggested that contextual conditions, such as poverty/deprivation 5,6,7,8,9, income 10,11,12, occupation 13 (e.g. manual and non-manual labor), employment/ unemployment 9,13,14,15,16,17, housing 18,19,20,21 (e.g. overcrowding), physical and built environment 12,18,22,23,24 (e.g. air and water pollution, green areas), access to equipment and services 25 (e.g. health, education, social support, sports and leisure), mobility and transportation 26, education 27, capital and social cohesion 28,29 (e.g. identity, trust in the institutions), social exclusion 30 (e.g. isolation, racism and discrimination), and safety 26,31 (e.g. public safety, crime and violence) impact the mental health of the population. The risk of mental disorders is thus influenced by the interaction between biological, psychological, social, environmental and institutional factors 1, which means that the social-environmental characteristics of the place where one is born, raised, lives, works and grows old influence individual and collective mental health 32,33,34. Currently, rapid and immoderate urbanization is a global phenomenon that occurs in association with other challenges, such as economic and financial crises 35, the ageing of the population and changes in family structure. These processes impact the health and wellbeing of the population and the communities, and may increase inequalities and generate inequities 36. Problems such as traffic jams, pollution, environmental degradation, housing, infrastructure and services that are inadequate or lack, formation of ghettos and clusters of poverty are compounded in urban space when territorial planning and development models cannot be adjusted in face of urban expansion phenomena 37. The development of urban space should consider its characteristics according to its multiple dimensions (e.g. social, economic, environmental), and aim at improving the quality of the physical space (built, connective, and relational), projecting its consequences on the health, quality of life and wellbeing of individuals and communities 38,39. Considering that intervention actions in the urban territory, whether of organization, planning and/or design, acting on, e.g., resources, infrastructure, and social conditions may promote or compromise the health of a community, increasing or mitigating health inequalities 36, it is necessary to generate systematic knowledge on the factors that control or promote health, thus supporting local agents in their political-strategic role to protect and promote health 40. This study was developed in the metropolitan areas of Portugal (Lisbon and Porto), and aims at: (i) identifying spatial patterns for the risk of hospital admission due to mental illness and the potential risk resulting from socio-spatial contextual factors that influence mental health, and (ii) analyzing the spatial association between the risk of hospital admission and contextual factors. Study area, data and methods A cross-sectional ecological study was conducted with the application of methods to assess spatial dependence and heterogeneity 41,42,43 in order to identify spatial patterns from the potential risk of socio-spatial contextual factors and the risk of admission due to mental illness in the Lisbon Metropolitan Area and the Porto Metropolitan Area


This study's aims are: (i) identifying spatial patterns for the risk of hospitalization due to mental illness and for the potential risk resulting from contextual factors with influence on mental health; and (ii) analyzing the spatial association between risk of hospitalization due to mental illness and potential risk resulting from contextual factors in the metropolitan areas of Lisbon and Porto, Portugal. A cross-sectional ecological study was conducted by applying statistical methods for assessing spatial dependency and heterogeneity. Results reveal a spatial association between risk of hospitalization due to mental illness and potential risk resulting from contextual factors with a statistical relevance of moderate intensity. 20% of the population under study lives in areas with a simultaneously high potential risk resulting from contextual factors and risk of hospitalization due to mental illness. Porto Metropolitan Area show the highest percentage of population living in parishes with a significantly high risk of hospitalization due to mental health, which puts forward the need for interventions on territory-adjusted contextual factors influencing mental health. Mental Health; Mental Disorders; Social Determinants of Health; Urban Health
Resumo Este estudo pretende: (i) identificar padrões espaciais do risco de internação por doença mental e do risco potencial resultante dos fatores do contexto com influência na saúde mental; e (ii) analisar a associação espacial entre o risco de internação por doença mental e o risco potencial resultante dos fatores do contexto, nas areas metropolitanas de Lisboa e Porto, Portugal.Foi conduzido um estudo ecológico transversal com a aplicação de métodos estatísticos de avaliação da dependência e heterogeneidade espacial.Os resultados revelam uma associação espacial entre o risco de internação por doença mental e o risco potencial resultante dos fatores do contexto com significância estatística e de intensidade moderada.Nas áreas, simultaneamente, de risco potencial resultante dos fatores do contexto e risco de internação por doença mental elevados, vivem 20% da população em estudo.Destacouse a Área Metropolitana do Porto com a maior porcentagem de população residindo em freguesias com risco de internação por doença mental significativamente alto, impondo a necessidade de intervenções sobre os fatores contextuais que influenciam a saúde mental, ajustadas aos territórios.

Introduction
Mental health is an essential component of one's wellbeing 1 ; however, mental disorders are currently one of the main causes of impairment, and high rates or morbidity and mortality 2 , particularly prematurely.Between 1990 and 2010, the weight of mental illness and substance abuserelated diseases increased 37.8% 3 .Portugal is one of the European countries with the highest prevalence of mental disorders 4 .
There is growing scientific interest in the study of the relationship between context (considered as the setting of residence/work/teaching/leisure) and health, and also in the influence of context as a trigger of health inequalities.
The risk of mental disorders is thus influenced by the interaction between biological, psychological, social, environmental and institutional factors 1 , which means that the social-environmental characteristics of the place where one is born, raised, lives, works and grows old influence individual and collective mental health 32,33,34 .
Currently, rapid and immoderate urbanization is a global phenomenon that occurs in association with other challenges, such as economic and financial crises 35 , the ageing of the population and changes in family structure.These processes impact the health and wellbeing of the population and the communities, and may increase inequalities and generate inequities 36 .Problems such as traffic jams, pollution, environmental degradation, housing, infrastructure and services that are inadequate or lack, formation of ghettos and clusters of poverty are compounded in urban space when territorial planning and development models cannot be adjusted in face of urban expansion phenomena 37 .The development of urban space should consider its characteristics according to its multiple dimensions (e.g.social, economic, environmental), and aim at improving the quality of the physical space (built, connective, and relational), projecting its consequences on the health, quality of life and wellbeing of individuals and communities 38,39 .
Considering that intervention actions in the urban territory, whether of organization, planning and/or design, acting on, e.g., resources, infrastructure, and social conditions may promote or compromise the health of a community, increasing or mitigating health inequalities 36 , it is necessary to generate systematic knowledge on the factors that control or promote health, thus supporting local agents in their political-strategic role to protect and promote health 40 .
This study was developed in the metropolitan areas of Portugal (Lisbon and Porto), and aims at: (i) identifying spatial patterns for the risk of hospital admission due to mental illness and the potential risk resulting from socio-spatial contextual factors that influence mental health, and (ii) analyzing the spatial association between the risk of hospital admission and contextual factors.

Study area, data and methods
A cross-sectional ecological study was conducted with the application of methods to assess spatial dependence and heterogeneity 41,42,43 in order to identify spatial patterns from the potential risk of socio-spatial contextual factors and the risk of admission due to mental illness in the Lisbon Metropolitan Area and the Porto Metropolitan Area

Study area
For this study, the two metropolitan areas of Portugal (Lisbon and Porto) were selected.These areas hold 43.4% (2011) of the Portuguese population, and represent 52.4% of the national purchasing power (2011).There are 18 municipalities in the isbon Metropolitan Area and 17 in the Porto Metropolitan Area.In these two regions, population and housing density are higher than elsewhere in the country.Their consolidated urban areas are characterized by the ageing of the population and the buildings 44 .Despite the common characteristics, there are differences between the two metropolitan areas, due to structurally distinct processes of metropolitanization: in the Lisbon Metropolitan Area, the processes of suburbanization are older, broader and more diversified socially; in the Porto Metropolitan Area these processes are more recent and not so significant, with areas of less density that reflect in situ urbanization phenomena (not based on pendular movements and in the presence of immigrant communities) 45 .
The two metropolitan areas were studied at the level of civil parishes (freguesias) (Lisbon: 211; Porto: 266), the lowest local level of Portuguese administrative division (Official Administrative Chart of Portugal.Limites Administrativos dos Concelhos e Freguesias de Portugal.http://www.igeo.pt/produtos/cadastro/caop/inicial.htm,accessed on 31/Jan/2014).This scale was selected due to availability and/or access to data relating to context and results in public health (hospital admissions).

Data
Data from the Diagnosis Related Group (DRG) general database 46 were used, made available by the Health System Central Administration (Administração Central do Sistema de Saúde -ACSS).The origin of this database is a classification system of hospitalized acute patients, in order to operationally define the products of a hospital.It was implemented in all hospitals of the Portuguese National Health Service (Serviço Nacional de Saúde -SNS), in 1990.The DRG pools patients in clinically coherent and similar groups according to the resources they use, this means, the set of goods and services that each patient receives according to their needs and to the disease that resulted in the hospital admission 46 .The information is systematized according to each admission (patient-discharge), with the collection of the variables that characterize the treated patients (e.g.main diagnosis, surgical interventions, secondary diagnosis [associated diseases and complications], procedures, age, sex, place of residence, length of hospital stay, and destination after discharge).This case-mix system was not designed with epidemiological, but with financial purposes, and is the first Portuguese database with clinical information 47 .However, its information is used in the academic environment for different purposes, namely studies of epidemiological analysis 48,49,50,51,52 .
The information was collected according to patient-discharge, stratified by 5-year age groups according to the main mental disorder diagnosis (ICD-9: 291, 303 -alcohol use-related mental disorders; 293 -transient mental disorders; 296, 311 -mood disorders; 295, 297, 298 -functional psychoses; 300 -anxiety, dissociative, somatoform disorders; 301 -personality disorders; 292, 304, 305 -drug use-related mental disorders; 306 -physiological malfunction arising from mental factors; 3071, 3075 -eating behavior-related mental disorders; 3074 -non-organic sleep disorders; 3078 -psychogenic-related mental disorders; 308 -acute reaction to stress; 309 -adjustment reactions; 316 -specific factors associated with diseases classified elsewhere; E95 -suicide and intentionally self-inflicted injuries).The selection of these hospital-admission causes was made with the use of focus-group qualitative technique, based, on one hand, on its importance and frequency (causes with higher number of admissions), and, on the other hand, on its higher susceptibility to the impact of contextual factors.
Between 2008 and 2012, 49, 140 patients-discharge were addressed in the two metropolitan areas.
Data (e.g.demographic, social, economic) were used that allowed context to be characterized by means of indicators whose influence on health is proved in the literature.Table 1 presents the list of study indicators that includes 21 context indicators.From this set, eight indicators were excluded (according to the limitations mentioned in the section Limitations).The 14 indicators that were included come from the last general population census survey (Portuguese National Statistics.Recenseamento da População e Habitação, 2011), and were collected for the 477 civil parishes of the study.

• Risk of hospitalization due to mental illness
To identify the risk areas for hospitalization due to mental illness, the smoothed Standardized Hospitalization Ratios (sSHR) were calculated, based on the Bayesian hierarchical model proposed by Besag et al. 53 , resolving the data variability-associated constraints (population dimension): only 3.8% of the study population is in the first quintile 54 .This method takes into account two types of data random effects -spatial and heterogeneous.The first considers the data spatial autocorrelation, the second relates to their non-spatial variability 55 .The number of expected hospitalizations was based on the indirect method, having as reference the metropolitan area population structure per age group, and using as standard the hospitalizations due to mental illness in the two metropolitan areas (standard region).In addition, based on the sSHR, the statistical significance of the risk of hospitalization due to mental illness was also calculated, defined by sSHR higher than 100.The classes of hospitalization risk due to mental disease (0.00-0.01; 0.01-0.02;0.02-0.08;0.08-0.09;0.09-1.00)come from this calculation.The first class (< 0.01) corresponds to areas in which the risk of hospitalization due to mental illness is low (less than 10%).
The last class (≥ 0.09) corresponds to areas in

Population density ü
Primary care consultations ü

Mean duration of pendular movements ü
Population with higher education ü

Blood donors ü
Beneficiaries of social welfare income ü Criminality ü which the risk of hospitalization due to mental illness is high (more than 90%).
For the presented methodology to be operational, the INLA method (Integrated Nested Laplace Approximations) was used through the INLA library, with software R.2.15.2 (The R Foundation for Statistical Computing, Vienna, Austria; http://www.r-project.org).

• Potential risk from the socio-spatial contextual factors
In order to identify potential risk areas from the socio-spatial contextual factors, methods to assess dependence and spatial heterogeneity were used 41,42,43,56,57 .The first step was the selection of socio-spatial contextual indicators (civil parish of residence), which, according to the literature, influence mental health.The indicators were submitted to an exploratory analysis that allowed verification of the association between each one of them and the sSHR.This association was measured through Pearson's Linear Correlation Coefficient (ρ).Later, the spatial dependence (autocorrelation) of the indicators that presented significant statistical association was analyzed with the use of Global Moran's I statistics.If any indicator had not shown significant global spatial autocorrelation (p-value < 0.01) it would have been excluded.This method consists of a spatial autocorrelation inferential model that quantifies dependence and spatial heterogeneity from the values of the samples to test the likelihood of each spatial unit being located in the different coordinates that make up the area under study, this means, the absence of standard (value of 0) 58,59 .Positive values (between 0 and +1) indicate direct correlation, and negative (between 0 and -1) evidence inverse correlation.
The second step was to apply Cronbach's alpha statistical test (α) to measure internal consistency and estimate reliability of the set of indicators with the highest co-variances (correlations between indicators) 60 .Later, considering the poor reliability obtained (α = 0.156), different tests with the same statistical measures were performed to identify and eliminate redundant indicators.For this methodological step, the design of an instrument was required to measure the potential risk from the socio-spatial contextual factors that presented, in its base, a set of indicators with acceptable internal consistency, in which each indicator contributed with new in-formation 61 .Thus, a set of ten indicators that showed higher reliability, homogeneity and consistency (α = 0.657) was identified, to analyze the influence of socio-spatial contextual factors on mental health.
In the third step the LISA (Local Indicator of Spatial Association) was used to identify the grade of similarity of difference between spatial units, upon confrontation with their neighbors, thus allowing the identification of clusters of units with identical values 58,59 , defined by spatial clusters of similarly low values (Low-Low and Low-High), and similarly high values (High-High and High-Low).
Spatial statistic tools were applied with the use of the extension Spatial Statistics Tools of the software ArcGis 10 (http://www.esri.com/software/arcgis/index.html) to make operational the methodology presented.
In the fourth step, areas of potential risk from socio-spatial contextual factors were identified for each metropolitan area, by means of scores of clustered areas.This potential risk resulting from socio-spatial contextual factors was found by spatial overlapping of the civil parishes classified at the LISA in spatial High-High and High Low clusters, and in spatial Low-Low and Low-High clusters three or more times.For its definition, the higher the value presented by the set of indicators selected through the Cronbach-alpha statistical test, the higher its influence on the increase of mental illness (except for the population growth indicator, which goes in the opposite direction, and was adjusted methodologically).
• Spatial association between the risk of hospitalization due to mental illness and the potential risk from socio-spatial contextual factors In order to estimate the spatial association/dependence between the two risks, a non-parametric hypothesis test, Pearson's chi-square test, was applied and its statistical significance was analyzed (p-value), considering significance levels p < 0.01.To assess the intensity of the association, Cramer's V contingency coefficient was used.

Risk of hospitalization due to mental illness
The rate of hospitalization due to mental disease in the Porto Metropolitan Area is twice as high as in the Lisbon Metropolitan Area (1,579/100,000 inhabitants, and 757/100,000 inhabitants, respectively).
From the distribution analysis of the risk of hospitalization due to mental disease (sSHR likelihood > 100) in the two metropolitan areas, in the period 2008-2012, a markedly urban geographical pattern was seen (Figure 1).In the civil parishes of the city of Porto and surrounding areas (that are part of Porto Metropolitan Area), a concentration of high risk areas of hospitalization due to mental illness was observed.In the Lisbon Metropolitan Area, the risk of hospitalization due to mental illness is high in Lisbon's city center and in some civil parishes in the municipalities of higher population density, particularly in the Northern bank.There is, however, higher dispersion of the risk of hospitalization.
By observing only the extreme classes, one sees that 27.7% of the total population live in civil parishes where the risk of hospitalization due to mental disease is considered low (less than 10%), and 66.7% live in civil parishes with high risk of hospitalization due to mental disease (more than 90%) (Table 2).

Association between contextual indicators and mental illness
Pearson's correlations (ρ) showed statistically significant association for all considered indicators, and sSHR with higher positive coefficients for the indicators Older people who live alone (ρ = 0.419), People working in trade and services (ρ = 0.365), and Unemployment rate (ρ = 0.348) (Table 2).Six indicators with significant and negative statistical association were identified, being the variable People working in industry the one with highest coefficient, ρ = -0.356.
According to Global Moran's I, there is significantly positive spatial association for all contextual indicators of the metropolitan areas of Lisbon and Porto, which indicate the presence of spatial clusters with similar values.
By applying Cronbach's alpha (α = 0.657, acceptable reliability), it was possible to select ten of these indicators: Unemployment rate, Population with higher education, Population density, Ageing index, Older people who live alone, Mean duration of pendular movements, Overcrowded households, Population growth, Active population with no economic activity, People working in trade and services.
LISA statistical analysis allowed the identification of spatial clusters with similarly low and similarly high values in these variables.Most of them have similar distribution: clusters with high values in the center of the metropolitan areas, and lower values in the outskirts.

S224
Cad. Saúde Pública, Rio de Janeiro, 31 Sup:S219-S231, 2015  Association between the risk of hospitalization due to mental illness and the potential risk resulting from socio-spatial contextual factors The areas of high potential risk resulting from socio-spatial contextual factors, which correspond to spatial units where contextual factors negatively influence mental health outcomes, have a high degree of coincidence with the civil parishes where the risk of hospitalization due to mental illness is high (more than 90%).Pearson's chi-square test proves the existence of a statistically significant association between areas of potential risk resulting from socio-spatial contextual factors and risk areas for hospitalization due to mental illness (119,318; p-value < 0.01).The intensity of this association is moderate, according to Cramer's V contingency coefficient (0.354).
Table 3 shows that in the areas of low potential risk resulting from socio-spatial contextual factors/low risk of hospitalization due to mental illness, around 7.5% and 8% of the population of

Discussion
The study investigated the spatial association between the risk of hospitalization due to mental illness and the potential risk resulting from socio-spatial contextual factors in the metropolitan areas of Portugal.With the use of Pearson's chi-square test and Cramer's V contingency coefficient, it was seen that this association is statistically significant, and of moderate intensity.The Bayesian hierarchical model applied in the calculation of the sSHR likelihood > 100 allowed the identification of areas where the risk of hospitalization due to mental illness is high: areas where some 30% of the metropolitan population live (Porto, 42.3%; Lisbon, 22.1%), with particular note to the areas of higher population density (the municipalities of Lisbon and Porto, and surrounding municipalities).According to other authors, anxiety and mood disorders are more prevalent among city residents 62 , and the incidence of schizophrenia and other mental illnesses is higher among people who were born and live in cities when compared to the overall population 63,64 .Spatial statistical analyses (Global Moran's I and LISA) led to the conclusion that some of the tested factors (regarding the demographic, social and economic context, for instance) are spatially concentrated, and form clusters of potential risk resulting from socio-spatial contextual factors that influence the mental health of individuals and the community at large, particularly in a setting of higher population density.These results confirm what other authors have revealed after the development of ecologic studies that made the spatial association between the socio-spatial context and mental health outcomes (morbidity and mortality) evident 41,42,43 .Other studies also revealed demographic characteristics, such as ageing 65,66 , and socioeconomic, such as economic inactivity 5,67 , unemployment 14,15,17 , level of school education 26 , characteristics of the built environment (e.g.housing conditions 18,19,20 and population density 24 ).
The cartographic representation of the highvalue significant clusters (High-High and High-Low) reinforces the identification of areas potentially vulnerable to mental illness.This spatial cluster profile is characterized by high values regarding population density, overcrowded households, older people living alone, population with higher education, occupation in the tertiary sector, and unemployment.It is to be stressed, however, that some civil parishes show high proportion of older lonely individuals and low proportion of overcrowded households.Exception is made for most civil parishes of the municipalities of Porto, Lisbon and Amadora.
It is also seen that in the two metropolitan areas, about 40% of the population lives in areas of high potential risk resulting from socio-spatial contextual factors.The figures are higher and of more concern in the Porto Metropolitan Area (43.3%).Coincidently, 51.1% of the Porto Metropolitan Area's population lives in areas with high risk of hospitalization due to mental illness (0.8-1.0).About 35% live in areas where the risk of hospitalization due to mental illness and the higher potential risk resulting from socio-spatial contextual factors are simultaneously concentrated.The Lisbon Metropolitan Area presents much lower figures: 23.8% of the population lives in areas of high potential risk resulting from socio-spatial contextual factors, 25.7% in areas of high risk of hospitalization due to mental illness (0.8-1.0), and 12.7% are at these two risks.Observing the prescription patterns for antidepressants, anxiolytics, sedatives, and hypnotics per 1,000 inhabitants, in the two metropolitan areas for the three-year period 2010-2012 (provided by ACSS/Invoice Conference Center (Centro de Conferência de Facturas, in 2012), the Porto Metropolitan Area shows higher values compared to those of the Lisbon Metropolitan Area (25% higher).
The spatially clustered areas of significantly low values (Low-Low, and Low-High), that correspond to clusters of low potential risk for mental illness resulting from socio-spatial contextual factors are peripheral to civil parishes of higher population density, that is, the metropolitan area center.This profile is characterized by low figures in regards to population density, household overcrowding, and unemployment.
This means that most areas considered to be at high potential risk for mental illness resulting from socio-spatial contextual factors correspond to the setting of a consolidated city, which confirm a number of studies that identified the association between living in big cities and having higher risk for mental illness 22,65,68 .In the metropolitan areas, however, spatial clusters were found with rural characteristics (e.g. in the municipalities of Arouca, Vale de Cambra in Porto Metropolitan Area; and Mafra and Montijo in Lisbon Metropolitan Area), away from the main urban centers, that present high concentration of risk factors, with high figures of older population, older people living alone, individuals with no economic activity, and high home/job commuting time.In fact, living in the countryside may also generate factors that favour the development of mental illness 69 .Higher isolation, poor transportation and communications, difficulties to access health and social services, and lack of social and occupational opportunities are potentially risky conditions for mental health.These differentiating characteristics may affect the understanding of the factors that influence mental health, and in measuring the risk of mental illness, considering the dynamic and multidimensional character of the analyzed phenomena.

Limitations
The ecologic nature of the study presents some limitations regarding its scale, data and method.The geographic unit of the study, the civil parish (freguesia, the lowest level local administrative unit in Portugal) is quite heterogeneous in character, and in some cases it does not represent the most suitable scale to gauge the spatial variation of contextual factors.On the other hand, despite the availability of some contextual data from some more detailed scales (e.g.statistical subsection), there was no access to hospital admission indicators from these scales.
It is also to be mentioned that the analysis of some context dimensions that impact mental health, like density, proximity and frequency of green areas 18,23,25 , the perception of unsafe spaces 26,31 , the lack of social cohesion 29 , were not included in the study due to limitations in data availability or access, and also time and/or cost constraints in their treatment.
The indicator of hospitalizations in SNS hospitals was used as a mental illness proxy, similarly to what was done in other studies 48,49,51,52 , due to the impossibility of access to all hospital admissions.However, given the nature of the Portuguese SNS (universal and general access, and mainly free of charge), public hospitals provide most of the healthcare and have most of the resources 70 .
Despite the recent evolution in reconciling patient-admission procedures in psychiatry clinics, admission criteria may be a hurdle to be taken into account when information is analyzed.However, the risk of admission is related to the patients' area of residence (civil parishes), and does not depend exclusively of the psychiatry clinic where the patient is admitted.
The interpretation of the results of this study should also take into consideration some methodology-associated limitations.To quantify the contribution of the different potential risk factors to explain mental health outcomes, and assess how the relationship between the explanatory variables and the dependent variable behaves in space, it would have been relevant to use other logistic regression methodologies that included spatial parameters, to allow the statistical associations and associated errors to be more accurately estimated.

Conclusions and recommendations
This is the first association study between socio-spatial contextual factors and mental health developed in the metropolitan areas of Portugal.The main results reveal the existence of spatial patterns of contextual factors that influence mental health, positively or negatively.The analysis of the two urban clusters presented advantages in comparing the investigated risk indicators, and confirmed that the areas identified as having high potential risk for mental illness resulting from socio-spatial contextual factors correspond to those areas of higher risk of hospitalization due to mental illness, in the two metropolitan areas.
The results found open a path for future investigations.Regarding the methodological factors, the need to apply logistic regression methodologies for the potential risk factors and mental health outcomes, considering the non-stationary, spatial and heterogeneity dependency of contex-tual factors and confounding factors, is underscored.On the other hand, it is necessary to go deeper in the study, using, for instance, gender disaggregated information and the analysis of the network of (and access to) psychiatry clinics.
The association found between the areas at risk of hospitalization due to mental illness and the areas of potential risk resulting from sociospatial contextual factors poses new challenges: (i) to the investigators, to seek evidence on measures to mitigate mental disease, to build capacity in the areas, in terms of resilience; (ii) to local agents, namely politicians and institutions, to promote the health of the population, particularly in the urban setting and in times of scarce resources and higher social vulnerability; (iii) in designing intersectoral policies and instruments for territorial action, at the level of land managing, planning and/or design, able to act on the socio-spatial contextual factors that influence mental health in each territory, adjusting the interventions to the needs that are found.

Resumen
Este trabajo pretende: (i) identificar los patrones espaciales del riesgo de hospitalización por enfermedad mental y del riesgo potencial resultante de los factores del contexto que influyan en la salud mental y (ii) analizar la asociación espacial entre el riesgo de hospitalización por enfermedad mental y el riesgo potencial resultante de los factores del contexto en las áreas metropolitanas de Lisboa y Porto, Portugal.Se ha realizado un estudio ecológico transversal con la aplicación de métodos estadísticos de evaluación de la dependencia y heterogeneidad espacial.Los resultados revelan una asociación espacial entre riesgo de hospitalización por enfermedad mental y el riesgo potencial resultante de los factores del contexto estadísticamente significativos y con intensidad moderada.Aproximadamente un 20% del total de la población del estudio habita en áreas de riesgo de hospitalización por enfermedad mental y riesgo potencial resultante de los factores del contexto.El Área Metropolitana de Porto tiene el mayor porcentaje de población en municipios con un riesgo de hospitalización por enfermedad mental significativamente alto, imponiendo la necesidad de intervenciones sobre los factores del contexto que influyen en la salud mental, ajustadas a los territorios.Salud Mental; Trastornos Mentales; Determinantes Sociales de la Salud; Salud Urbana Contributors A. Loureiro, C. Costa and R. Almendra contributed to the design and project, data analysis and interpretation, writing of the article and critical review of the intellectual content.A. Freitas contributed to the writing of the article and critical review of the intellectual content.P. Santana contributed to the writing of the article, critical review of the intellectual content, and approval of the final version to be published.

Figure 1 Areas
Figure 1 Areas at risk of hospitalization due to mental illness, and potential risk resulting from socio-spatial contextual factors.Metropolitan areas of Lisbon and Porto, Portugal.

Table 1
List of contex-related study indicators.

Table 2
Pearson's correlation coefficient (ρ and p-value) between the smoothed Standardized Hospitalization Ratio (sSHR) and selected contextual indicators in the Metropolitan areas of Lisbon and Porto, Portugal.

Table 3
Population at risk of hospitalization due to mental illness and according to the potential risk resulting from socio-spatial contextual factors.Metropolitan areas of Lisbon and Porto, Portugal.Lisbon Metropolitan Area and Porto Metropolitan Area live, respectively.On the other hand, in the areas of high potential risk resulting from socio-spatial contextual factors/high risk of hospitalization due to mental illness, 12.3% of the population of the Lisbon Metropolitan Area, and 31.4% of the Porto Metropolitan Area live. the