Housing Supply and How It Is Related to Social Inequalities—Air Pollution, Green Spaces, Crime Levels, and Poor Areas—In Catalonia

We carried out a search of over 12,000 houses offered on the rental market in Catalonia and assessed the possibility of families below the poverty threshold being able to rent these homes. In this regard, we wanted to evaluate whether the economic situation of families is able to influence their social environment, surroundings, and safety. We observed how their economic situation can allow families the possibility of developing a life without exposure to health risks, and how economic constraints result in disadvantages in several areas of life. The results show how families at risk of poverty live in less favourable conditions and experience a widening of different gaps, with current prices leading to a possible poverty trap for the most disadvantaged groups. The higher the percentage of the population below the threshold, the lower the possibility of not being able to rent a house compared to areas with a lower prevalence of population below the threshold. This association was observed both when considering the risk linearly and non-linearly. Linearly, the probability of not renting a house was reduced by 8.36% for each 1% increase in the prevalence of population at risk of extreme poverty. In the second, third and fourth percentage quartiles, the probability of not being able to rent a house decreased by 21.13%, 48.61%, and 57.79%, respectively. In addition, the effect was different inside and outside of metropolitan areas, with the former showing a decrease of 19.05% in the probability of renting a house, whereas outside metropolitan areas the probability increased by 5.70%.


Introduction
Social inequality can be viewed from different perspectives. These can be political, economic, social, or health-related, among others, and they can be interrelated [1][2][3][4][5]. Consequently, inequality culminates in the generation of situations of marginalisation and social exclusion. This problem is highlighted by the policies pursued by governments and institutions to try to minimalize these inequalities.
If we focus on income inequalities, there are several policies pursued in Europe to minimise the gap including minimum wages, taxes for redistributive purposes, and the establishment of welfare that guarantees minimum services for the whole population. As Piketty shows, the growth of economies alone does not reduce inequalities stemming from income and wealth [6]. These inequalities originate from the poor distribution of wealth among the population. However, the discourse around this line of thought does not revolve around an element that is common in the lives of everyone: housing.
Housing is one of the inequalities generated within the economic sphere and encompasses under-housing, housing deficiencies, unhealthy households, sub-renting, employment, unhealthy environments, and the cost of housing; all of which are elements that lead to social exclusion and other inequalities. Housing was declared a universal right in 1948 meaning that 41% of the population occupies just 1.97% of the region. By the same token, 66% reside in cities with more than 20,000 inhabitants which, in turn, is equivalent to just 6.61% of the total territory [32].
This rural/urban dichotomy has direct implications for inequality, and in those that affect living conditions above all. Urbanization has been present in many areas of the Catalan territory at the same time as inequalities have been accentuated and residential segregation manifested [33,34]. Recently, house prices have generally increased, especially in the metropolises [35][36][37]. In 2020, rental prices had increased so dramatically in Catalonia that a law was passed to regulate them. This law allows rents to be capped based on the Catalan Housing Agency's Average Price Index, which sets an average reference price for specific areas where abusive price increases have been identified. In addition, with the appearance of homes destined for short-term rental platforms such as Airbnb, the number of homes available for rent has been reduced. This reduction is even greater in popular tourist areas and has resulted in a 7% increase in rental prices [38,39].
These circumstances end up affecting those with fewer economic resources as they must allocate a larger part of their income to cover housing, often at the expense of living in a healthy environment [40]. This paper aims to study the conditions under which families who are below the poverty threshold can rent a home. Our hypothesis is that the socially excluded cannot rent a property with conditions that ensure an optimal standard of living. We also assume that to have a home to live in, low-income families must interact with environments of high social inequality.
Our objective in this work is to study the ability of people at risk of social exclusion to access the rental housing market in Catalonia at the small scale (either municipality or district). Specifically, we evaluated the association between the possibility that a family at risk of exclusion does not rent a home and the type of socio-economic environment, the nearby urban greenery (green areas per inhabitant in square meters, the Normalized Difference Vegetation Index (NDVI) in a range of 500 m), the level of exposure to air pollution (PM 10 , NO 2 and O 3 ), and the level of known crimes in the area.

Area and Period of Study
We used a cross-sectional observational design, and the data were extracted from multiple databases in September 2021 to study accessibility. The area of study consisted of the geolocated information of each home combined with the information from the small areas (either municipality or district), to enable access to the most granular information possible. The study is based on data from households for rent in September 2021.
In Catalonia, as in the rest of Spain, only municipalities with 75,000 inhabitants or more are divided into districts. The districts, although they are an administrative division, group neighbourhoods with noticeable homogeneity in terms of socioeconomic variables (similar population density, similar disposable income, similar inequality index, etc.), see  In addition, the districts are the smallest administrative unit for which information is obtained for the variables of interest in this study (i.e., housing).            The data used were extracted from different sources, all of them official, and translated into a dataset of more than 50 variables (see Supplementary Table S1). The sources used to carry out the study were: Statistical Institute of Catalonia (IDESCAT), Carto-    The data used were extracted from different sources, all of them official, and translated into a dataset of more than 50 variables (see Supplementary Table S1). The sources  The data used were extracted from different sources, all of them official, and translated into a dataset of more than 50 variables (see Supplementary Table S1). The sources used to carry out the study were: Statistical Institute of Catalonia (IDESCAT), Cartographic and Geological Institute of Catalonia (ICGC), Government of Catalonia Open Data, the Mossos d'Esquadra police force, the National Statistics Institute (INE), Habitaclia estate agency and the Research Group on Statistics, Econometrics and Health (GRECS), University of Girona.

Homes
A web scraping of the Habitaclia website was carried out to determine the number of rental homes available in Catalonia. After reviewing the main rental platforms in Spain the Habitaclia portal was chosen because it is not only one of the platforms with the largest number of homes registered on it, but its web structure also allowed greater ease of data extraction for subsequent processing and geolocation.

Web Scraping
Web scraping (a technique using software to extract public information from websites in an automated way) allowed the following features of each home to be obtained: price, m 2 , number of toilets and rooms, province, municipality, district, and street (where the house is located). The total number of rental homes in Catalonia was 12,796, comprising 11,320 homes in the province of Barcelona (mean: 58

. Homes
A web scraping of the Habitaclia website was carried out to determine the number of rental homes available in Catalonia. After reviewing the main rental platforms in Spain the Habitaclia portal was chosen because it is not only one of the platforms with the largest number of homes registered on it, but its web structure also allowed greater ease of data extraction for subsequent processing and geolocation.

Web Scraping
Web scraping (a technique using software to extract public information from websites in an automated way) allowed the following features of each home to be obtained: price, m 2 , number of toilets and rooms, province, municipality, district, and street (where the house is located). The total number of rental homes in Catalonia was 12,796, comprising 11,320 homes in the province of Barcelona

Geolocalisation, Atypical Values, Errors, and Debugging the Web Scraping
The data obtained from the web scraping were used to localise each home in its town and district of reference. Of the total number of homes obtained (n = 12,796), n = 11,289 were successfully geolocated. This debugging reported the following errors: platform errors (n = 3); homes with some missing information (n = 42); and homes where the geolocated municipality and province do not match (n = 142). All homes that were atypical due to their high rental price and could affect the objective of the study were also discarded (n = 1320).

Dependent Variables
We considered, as a dependent variable, a variable indicating that, in September 2021, the home was not rented (value 1 and 0 if it was rented).

Explanatory Variables -
Environmental and demographic data The cultural diversity [41] of the people living in a neighbourhood or area determines the socioeconomic level of its population. This socioeconomic level directly affects the area or neighbourhood, generating either favourable economic growth or reversing this growth [42].
The data were obtained taking the district in each town where the home was located as the reference. If they were subject to statistical secrecy, the value for the town itself was used. The variables used to determine the socioeconomic fabric of the territory were: average age, average size of homes, number of single-person households, and the Gini index [43]. -

Vegetation and the presence of greenery
The relationship between the presence of parks, gardens, trees, and other green elements has been scientifically proven [44][45][46] to be linked to health [47]. The NDVI [48] and the surface area of green areas per inhabitant in square metres [49] were used to study the relationship between the homes and the surrounding greenery. The WHO

Geolocalisation, Atypical Values, Errors, and Debugging the Web Scraping
The data obtained from the web scraping were used to localise each home in its town and district of reference. Of the total number of homes obtained (n = 12,796), n = 11,289 were successfully geolocated. This debugging reported the following errors: platform errors (n = 3); homes with some missing information (n = 42); and homes where the geolocated municipality and province do not match (n = 142). All homes that were atypical due to their high rental price and could affect the objective of the study were also discarded (n = 1320).

Variables Dependent Variables
We considered, as a dependent variable, a variable indicating that, in September 2021, the home was not rented (value 1 and 0 if it was rented).

− Environmental and demographic data
The cultural diversity [41] of the people living in a neighbourhood or area determines the socioeconomic level of its population. This socioeconomic level directly affects the area or neighbourhood, generating either favourable economic growth or reversing this growth [42].
The data were obtained taking the district in each town where the home was located as the reference. If they were subject to statistical secrecy, the value for the town itself was used. The variables used to determine the socioeconomic fabric of the territory were: average age, average size of homes, number of single-person households, and the Gini index [43].

− Vegetation and the presence of greenery
The relationship between the presence of parks, gardens, trees, and other green elements has been scientifically proven [44][45][46] to be linked to health [47]. The NDVI [48] and the surface area of green areas per inhabitant in square metres [49] were used to study the relationship between the homes and the surrounding greenery. The WHO recommendation regarding the latter is that every city should have at least 9 m 2 of greenery per inhabitant [21].
In addition, the relationship between the presence of urban vegetation and the quality of life and health is known. There is also a relationship between urban vegetation and physical activity and mental health [50].
To observe the nearby NDVI of each house, a 500-metre buffer was constructed [51], where each house acts as a centroid of its own buffer. In this way, the vegetation close to each house can be analysed.

− Air pollutants
In recent years, there has been an ever expanding amount of scientific evidence concerning increased levels of pollution [52][53][54]. Consequently, pollution is highly relevant when considering the development of a healthy lifestyle.
The following variables regarding air pollution [55,56] were used: particulate matter equal to or less than 10 microns (PM 10 ), nitrogen dioxide (NO 2 ), and ozone (O 3 ). In 2021, the WHO recommended new levels of contamination [57]. Families living in areas below these pollution levels will see their cardiovascular and respiratory health improve, in addition to reducing their burden of morbidity and mortality. We created two dummy variables for each pollutant and looked at whether homes were in locations where air pollution was above or below the old and current WHO limits.

− Safety
The safety of a town or area is an important element in determining its socio-economic status [58]. Low-income areas are directly related to different types of crime [59]. Although Europe in general does not have such a high or significant ratio as other countries [60], it is still an element to consider, especially for families who rent [18]. The number of crimes is also related to the movement of drugs, gangs, and other elements that can impact an area and condition the lives of the families living there [61].
The total number of crimes known to the Catalan police force (Mossos d'Esquadra) in the Basic Police Area (ABP) of each home was used [62]. The Mossos d'Esquadra are responsible for citizen safety, public order, investigation, and traffic control in Catalonia.

− Ability to pay
The rental price of homes determines the type of families who will be able to live in an area [63]. Each small area (either municipality or district) has similar prices for a home, which vary depending on the features, the socioeconomic level of the neighbourhood, the presence of nearby urban greenery, and how safe the area is. Migratory movements also affect the socioeconomic levels of the population [64].
The threshold for Catalonia (EUR 11,365.60) [65] was used to determine which flats could be rented by families at risk of poverty. The social structure of the territory was also obtained through the variables presented above. We have controlled the neighbouring areas of each house to observe their closest socioeconomic environments. We do so to observe the interaction of each dwelling with the areas close to them.
The variables linked to income to determine the ability to pay were net income per person per household, median per unit of consumption, and average salary [43]. The percentages of people at risk of poverty (60% of the median) and extreme poverty (40% of the median) were also obtained.

Control Variables
We controlled for different types of variables: features of the home, social characteristics, population size, and typologies of areas. More specifically, the area in square meters, and the number of rooms and toilets were used to consider the different features. In terms of population characteristics, we used the number of inhabitants, the average size and age of the home, and the population density in the district where each home was located.
The differences presented in the small areas (either municipality or district) forced the creation of multiple control variables to capture the heterogeneity of the territory: size of each district in square kilometres (source: extraction of the area through the municipal raster [66]); the variable density_urban, which measures the density of the urban areas of each town (source: data from the urban map of Catalonia, [49]); the variable area_metro, which captures whether or not the district in question belong to the metropolitan area of Barcelona (source: authors' own); the variable capitals (source: authors' own) to capture whether or not the district belongs to a provincial capital; and the variable density_ (source: authors' own), which measures whether the district is in a high-(High) or low-(Low) density area, depending on the reference population. Apart from the variable density_urban, the variables were observed at the district level.

Geospatial Groupings
The data were placed into four groups. The first set of data was georeferenced and applied to the characteristics derived from the dwellings as well as the NDVI and the dummy control variables. The second set was grouped by district or town depending on the availability of the information. The data in this second group correspond to the socioeconomic data and the dichotomous variables of rural/urban areas and belonging to the metropolitan area of Barcelona. The inhabitants by districts are distributed as follows: mean: 6167 inhabitants, standard deviation: 16,556.16 inhabitants, median: 1730 inhabitants, first quartile -Q1-: 433 inhabitants, and third quartile -Q3-: 6251 inhabitants. By municipality they are distributed as follows: mean: 16,378 inhabitants, standard deviation: 258,190.7 inhabitants, median: 961 inhabitants, first quartile -Q1-: 322 inhabitants, and third quartile -Q3-: 3903 inhabitants.
The third type of grouping included the Basic Health Areas (ABS), which are defined as the territorial units through which the primary health care services are organized [67]. These can have different dimensions depending on the accessibility of the population to be served. The variables in this third grouping consist of the air pollution data. The population distribution of the ABS is: mean: 20,636 inhabitants, standard deviation: 9192.051 inhabitants, median: 20,638 inhabitants, first quartile -Q1-: 14,018 inhabitants, and third quartile -Q3-: 26,558 inhabitants.
The last grouping includes the Basic Police Areas (ABP), which are defined as the basic territorial implementation units, themselves defined using territorial and police criteria [64]. The data in this last group are those related to the number of crimes. The distribution of people of in the ABP is: mean: 381,153 inhabitants, standard deviation: 577,201.9 inhabitants, median: 129,374 inhabitants, first quartile -Q1-: 65,844 inhabitants and third quartile -Q3-: 258,179 inhabitants.

Data Analysis
We specified generalised linear models (GLM) with variable response of a Bernoulli distribution, according to the possibility of renting a home, i.e., a variable indicating that, in September 2021, a specific home (of the 11.289 homes analysed) was not rented.
We included as the following explanatory variables in the GLM: the percentage of the population at risk of social exclusion in the district of each home; the vegetation index (also in the district); the number of m 2 of green area per inhabitant in the town of each home; dichotomous variables indicating if the values of the air pollutants (PM 10 , NO 2 and O 3 ) predicted in the district exceed the limits defined by the WHO; and the number of known crimes in the district of each home. We also controlled for the control variables defined above.
For the effect of the metropolitan area on the possibility of a family at risk of social inclusion renting a home, the model was re-estimated, including the interaction of the metropolitan area.
Details are shown in the Supplementary Material.
The values of the coefficients and the Odds Ratios generated through the model were used to study which variables affect the event of households at risk of poverty renting a home.
We included the variables linearly (that is, the response of the dependent variable is the same to an increase in the variable, regardless of the level of the variable) and non-linearly (that is, the response of the dependent variable to an increase in the variable will depend on the level of the level of the variable) in the model, testing different reference categories to see how they interacted with the event of households at risk of poverty renting a home.
The models were compared using the Akaike Information Criterion (AIC), which reviews and penalises the flexibility of the model [68] and the control of multicollinearity.

Bivariate Analyses
The results are presented in Tables 1 and 2 (bivariate analysis). Table 1 considers whether the home could be rented by a household at risk of social exclusion. Table 2 also considers the area where the home is located, either within the Metropolitan Area (AMB) or Outside the AMB (OAMB). The variables show quite asymmetric distributions, implying that only robust statistics (median and first and third quartile) should be used when interpreting the data.  The results of the bivariate analysis (Table 1) show that generally the properties that cannot be rented by families at risk of social exclusion tend to be found in areas with a high Gini index (Can rent: 32.9, Cannot rent: 36.1). It is also observed that the percentage of people at risk of social exclusion is lower (Can rent: 14.7, Cannot rent: 13.3). However, it should be noted that the percentage of families living in extreme conditions does not vary depending on whether the houses can or cannot be rented by households with adverse social conditions (Can rent: 7.7, Cannot rent: 7.7). Table 2 shows how, in both areas, the homes that cannot be rented by families at risk of poverty are in the areas with a higher Gini score (AMB-Can rent: 31.5; Cannot rent: 32.45. OAMB-Can rent: 34.1; Cannot rent: 36.1). It can also be seen how these homes are found to be in areas where there is a lower percentage of people at risk of poverty (AMB-Can rent: 16.3; Cannot rent: 15.4. OAMB-Can rent: 14.6; Cannot rent: 13.3). However, it can also be seen that the percentage of people below the poverty line is higher outside the metropolitan area than inside it. There is also a higher percentage of people in extreme poverty outside of the metropolitan areas. It can be observed that outside of the metropolitan area there are variations among the homes to which families with social difficulties and those that do not have access (AMB-Can rent: 7.9; Cannot rent: 7.6. OAMB-Can rent: 7.7; Cannot rent: 7.7).
The number of rental homes available for a family at risk of social exclusion that would allow them to save at least 30% of their income is just 9 out of the total of 11,097 homes (all of them outside the AMB). Income also shows how families with social limitations can live in areas where gross income per capita income is lower (Can rent: 41,990; Cannot rent: 54,708). If we look at the situation by area, the phenomenon is the same but the value for gross income per person and per household is higher within the AMB.
Green areas present no differences in terms of the homes that can be rented and those that cannot (Can rent: 7.847, Cannot rent: 7.847). There is, however, a difference regarding the NDVI near to the homes, with those that cannot be rented presenting a lower value (Can rent: 0.226, Cannot rent: 0.221). If we analyse the green areas, it is outside the metropolitan area that there are higher values of NDVI and green areas. Notably, when differentiating the areas it was observed that the homes that cannot be rented have higher NDVI values (AMB-Can rent: 0.285, Cannot rent: 0.312. OAMB-Can rent: 0.213, Cannot rent: 0.218).
In general, the homes that can be rented have lower levels of PM 10 23.893) are reversed and are higher in the houses that can be rented by low-income families. Another way to analyse pollutant levels is by using the limits proposed by the WHO. If we take the former level recommended by this organisation, we can see that most properties are above the recommended PM 10 levels. However, with the new WHO-recommended levels, the number of households with an optimal level of pollution is reduced, especially regarding NO 2 .
If we analyse the number of crimes, the analysis shows that this number is lower for properties that can be rented by families with financial difficulties (Can rent: 9780; Cannot rent: 14,303). When observed by area, it is outside the metropolitan area that families at risk of poverty live in homes where there are more crimes (OAMB-Can rent: 9121; Cannot rent: 8727). In contrast, in the metropolitan area, crime is higher in areas where homes can only be rented by wealthy families (AMB-Can rent: 14,303; Cannot rent: 15,074).

Results of the Estimation of the Generalised Linear Models (GLM)
Tables 3 and 4 show the Odds Ratio of the GLM estimation models, with which we looked for the association between air pollutants, socioeconomic status, and the vegetation near a home and the possibility of not renting/renting by a family at risk of social exclusion. We controlled for socioeconomic and demographic variables and non-observed confounders for all these factors. Tables 3 and 4 also show the 95% confidence intervals (95% ICr, as of now) and their p-value. The variables on income (per person and per household) were not significant in terms of the possibility of renting. Similarly, the new limits recommended by the WHO and the possibility to save were not significant. Table 3. Association between air pollutants and socioeconomic variables with the possibility of not renting a home for a family at risk of social exclusion.    (***) = p ≤ 0.001; (**) = p ≤ 0.01; (*) = p ≤ 0.05; (·) = p ≤ 0.1. Source: authors' own elaboration. 1 Additionally, adjusted for the control variables.
There is a relationship between areas with a high percentage of people below the poverty line and the ease of renting a home for families at risk of vulnerability. The higher the percentage of population below the threshold, the lower the possibility of not being able to rent a home compared to areas with a lower percentage of population below the threshold. In the second quartile, the probability of a home not being rented decreases by 21.13% and by 48.61% and 57.79% in the third and fourth quartiles. With crimes, the phenomenon is reversed, the greater the number of crimes, it's harder not to rent compared to homes in areas where there are fewer crimes. In the third quartile, the probability of not renting increases by 43.42% and in the quartile with the highest number of crimes, the probability increases by 320.64%.
Relationships were also observed between the possibility of not renting a home and pollutants. For the PM 10 pollutant, the second and last quartiles are less likely not to be rented than the homes in the first pollution quartile. The odds decrease by 31.59% and 36.21%, respectively. For the NO 2 pollutant, the probability of not being rented decreases to a lesser extent compared to the least polluted quartile. In the second quartile the probability decreases by 56.01%, and in the third and fourth quartiles the probability decreases by 19.09% and 18.66%, respectively. For O 3 , the higher the level of contamination, the greater the probability of not being able to be rented compared to less contaminated homes. In the third quartile the probability of not being rented increases by 58.26% and in the fourth quartile the probability is 62.28%.
In addition, if the homes are in areas above the old limits indicated by the WHO, the probability of not renting decreases by 46.85% if they exceed PM 10 levels and by 28.77% if they exceed NO 2 levels.
Regarding green spaces, for each increase of one m 2 of green area per inhabitant, the probability of not renting the home will increase by 190%. If we look at the NDVI close to the home, the higher the vegetation index, the more difficult it is not to rent compared to homes in areas where there is a lower index. In the second quartile the probability increases by 19.46%, in the third quartile by 39.42%, and in the quartile with the highest number of crimes the percentage is a little lower at 31.55%.
If we carry out the study considering the areas where the homes are located, we can detect divergences between them. In this case, the study was performed with linear variables to facilitate interpretation and comparison.
The probability of not renting a home is reduced by 8.36% for every 1% increase in the population at risk of extreme poverty. The effect is different inside and outside the metropolitan area. Within the metropolitan area, the probability reduction is 19.05%. On the other hand, outside the metropolitan area the probability increases by 5.70%. Crimes have a similar effect in the two zones. For each crime that occurs, the probability increases by 0.005%. Within the metropolitan area it increases by 0.014%, while outside the metropolitan area the probability increases by 0.004.
If we look at pollutants, the effects are different for each 1 µg/m3 increase. For each increase of 1 µg/m 3 in the PM 10 pollutant, the probability of not renting decreases by 2.93%. We observed a different pattern between areas. In the metropolitan area, the probability decreases by 7.03%. Outside the area the probability increases by 8.08%. The NO 2 pollutant had the opposite effect between areas to PM 10 . For each increase of 1 µg/m 3 , the probability of not renting increases by 0.38%. Within the metropolitan area the probability increases by 2.30%, outside the probability it decreases by 2.36%. For the pollutant O 3 , for each increase of 1 µg/m 3 the probability of not renting decreased by 1.32%. Inside and outside the metropolitan area, the probability of not renting increases by 1.96% and 0.45%, respectively.
As for green areas, for each increase of 1 m 2 of green area per inhabitant, the probability of not renting will also increase by 0.68%. Within the metropolitan area, the probability will increase by a greater magnitude, 4.17%. On the other hand, outside the metropolitan area the probability will increase by 0.75%. The nearby NDVI showed a different pattern to the m 2 of green area. For every 1% increase in the index, the probability of not renting decreases by 78.21%. Within the metropolitan area the probability increases by 125.15% and, on the other hand, outside the metropolitan area the probability decreases by 60.35%.

Discussion
The reduction of poverty and related inequalities is one of the great struggles repeated cyclically throughout history. In recent years, it has been shown that increased productivity in not reflected in society in terms of salary increases or a greater ability to cover basic material needs [94]. We can also find in the literature multiple studies on where and how poverty is distributed [95][96][97] among the different social classes [98].
As has been shown, the lower and low-income social classes have higher mortality rates than the wealthy classes [99][100][101]. Although the aim of this study was not to determine the relative risk of mortality of families below the poverty line, we find significant relationships between the areas with the highest levels of pollutants, PM 10 , NO 2 , and O 3 , and the tendency for these families to live there. As is well known, the most disadvantaged social classes tend to have higher exposure to environmental pollutants than the rest of the population [102], causing a higher probability of developing diseases [103][104][105][106].
There are various articles that study the relationship between exposure to environmental pollutants and social class [107][108][109][110]. Most of them are based on the individual or the socio-economic status (SES) of the areas, and the authors relate these to the levels of environmental pollution recorded. As in some other studies [111,112], our work was carried out with reference to housing, subsequently linking this to the area where the homes are located. In Oslo [111], it was found that socially deprived neighbourhoods have a greater exposure to air pollution. Wheeler and Ben-Shlomo [112], analysing a survey from England, found that socially deprived neighbourhoods have higher exposure to air pollution. However, our consideration is the possibility of the home being rented to low-income families, based on the real market supply. Notably too, our study includes different types of cities, while previous studies have generally considered metropolises and major cities. Yet, despite these differences, the results are similar, only differing when we analyse our results by area type. In this regard, the similarities with previous studies are accentuated in the more urbanised areas and differ in the more rural areas. These differences may be due to variations in the type of territory, the vegetation levels, and the socioeconomic and demographic status of the territories studied. We must also consider the possibility that the new generations in Catalonia have changed their housing consumption patterns and prefer to rent rather than buy. In fact, the most recent studies [14] show that young people want to buy but cannot.
This difference between zones is repeated among various key variables, but with a reversed trend. Urban greenery per capita, for example, is a green variable of high interest to most major cities worldwide [113,114]. These cities stand out for their high population density [115,116], accentuating problems of access to vegetation, while the direct relationship between vegetation and health is well known. Even in large cities, policies and regulations are in force to increase and protect the number of square kilometres of green areas per capita and their vegetation [117,118]. There are several studies linking inequality and green areas [119,120]. As with previous studies, we found that an increase in square metres of green space per capita acts as a barrier to access for low-income families. The same phenomenon occurs if we look at studies of NDVI close to the home. When we look at the phenomenon in rural areas, the patterns of urban green space per capita and NDVI are reversed. It is the areas with less urban green space that generate access difficulties for families at risk of poverty. This phenomenon can be explained by the fact that there is a large volume of greenery in the rural areas of Catalonia. The evidence shows that historically there has been residential segregation, with poverty concentrated in zones or neighbourhoods [121,122]. These areas end up becoming communities of vulnerable people, perpetuating the poverty trap [123,124]. In our study, we observed this very trend. The higher the percentage of the population at risk of poverty, the more likely they are to rent these homes. Results show [125] that approximately 18% of European households and 10% of Spanish households have difficulty meeting their monthly payments. In our study, we found that there is a minimum population of 7.7% at risk of social exclusion who may present these difficulties, even in affluent neighbourhoods. These differences can be explained by the fact that in the present study we only considered data from our territory. If we differentiate the data by areas, we can see that in rural areas there is a low segregation of the population with low resources in the most precarious areas, which is not the case in urban areas.
The international literature shows that poverty is one of the most stable predictors of crime [126,127]. Moreover, the degree of urbanisation and safety are also directly related to the crimes committed [128]. Areas with greater social deprivation are associated with a higher level of crime [129,130]. Our results show that the most depressed areas have the lowest crime rates. If we look at behaviour in rural areas, it does reproduce the logic pointed out in previous studies. However, in urban areas, housing to which low-income families do not have access is found in the neighbourhoods with the highest crime rates. There are two possible reasons for these differences. They could be explained by the type of data identified as crimes, since there may be limitations when it comes to capturing data through administrative record channels. It could also be possible that crimes are not recorded in the place where they occurred, but rather in the place where the people who commit them live. We find it plausible to think that people who commit crimes do so more in rich areas than in poor ones.
Our study, unlike most of those mentioned above, performs an analysis of housing, allowing data to be obtained inside and outside large cities to see the similarities and differences. We also focused on small areas (either municipality or district), although this made the study more difficult because it meant creating different control variables. To this effect, we obtained data of multiple types that have an impact on inequalities in large cities and the most depopulated areas.

Conclusions
Out study may have some limitations stemming from its design. Firstly, the ecological inference fallacy must be considered when working with an ecological study. This fallacy complicates inferences at the individual level, given that there can be confounding elements inherent in the design typology. However, we tried to control the bias in the models as far as possible by including social, environmental, demographic, geographical, crime, and confounding variables, all of which were addressed at a small territorial level. It would be interesting to be able to carry out the study through individuals rather than through the possibility of renting to be able to verify whether these data are correct or, conversely, to show new variations in the inequalities.
Secondly, the processing of data on different scales may be hiding inequalities and altering the study. This could be especially pertinent with reference to rural areas where it is more difficult to obtain the same level of data granularity as in urban areas. Furthermore, a family living in one area does not necessarily share the same average value as another family in the area. This fact leads to a possibly random error of measurement. This explains why the data have been measured with error, because otherwise we would obtain inconsistent estimators [131]. Lastly, we observe that there is a greater volume of data in the Barcelona area than in other areas. Notably, this province is home to more than 73% of the total population of the territory.
We believe these limitations are offset by the strengths of the study. Firstly, we conducted a study using small areas that allowed district data to be analysed. Although we are not the only authors to conduct a study of small areas, the model responds well to both small and rural areas. Secondly, the models obtained used multiple observed and unobserved confounders. Thirdly, we combined an interesting set of variables that are closely linked to inequalities. All of them stem from poverty and although studied in a combined way, our model can respond to multiple intersectionalities. Fourthly, the data obtained study inequality through the market supply curve, allowing the reality of the housing market at any given time to be captured and its limitations to be observed, which would be more difficult if worked from the demand curve or the balance point.
Lastly, we obtained a model that encompasses different key aspects caused by poverty: environmental pollution, the poverty cycle and trap, crime, and vegetation in relation to small areas and of different types.
Although the present study only considers outdoor pollutants, it would be interesting to obtain a more accurate reading of the exposure of each home to indoor pollution. It would also be interesting to be able to cross reference the different variables in the model at the individual level and see how they develop in the different districts.It would be advisable to carry out a study at the Catalonia level to determine if there are areas that have already become or are in the process of becoming places where people with high or low purchasing power are concentrated in order to deconstruct these areas of poverty or wealth.
We think that this article can shed light on the housing problem in Catalonia and that our results can be used to adjust the different policies implemented in the fight against poverty. In the first place, inequality is not generated solely by a lack of economic resources. Policies on environmental contamination should be accelerated to reduce future morbidity problems in the population, which will culminate in affecting future public health policies. In addition, a way must be found to encourage and help low-income families to save so as not to fall into the poverty trap while ensuring a healthy environment to reduce the latent inequality present throughout the territory. These social, economic, and environmental policies must be resolved today so as to have a smaller, less significant impact on future policies and on the Catalan economy. Finally, the model is easily reproducible at other scales, which makes it possible to reduce the ecological fallacy and also to be used in other countries.   Data Availability Statement: All the data, including the code to produce the figures, can be requested from the first author (xperafita@dipsalut.cat).