## 2 Materials and Methods
### Methods
#### 2.2.3 Data Analysis  
The analysis of the energy efficiency of dwellings has been carried out at the building level. Since the database includes the cadastral records of each dwelling, the building energy efficiency calculation proposal of [PERSON] et al. (2006) is used to find the weighted average consumption and CO\({}_{2}\) emissions of the building (Equations (1) and (2)). \[EP_{nr,arg}=\frac{\sum_{i=1}^{n}EP_{nr,i}\cdot A_{i}}{\sum_{i=1}^{n}A_{i}} \tag{1}\] \begin{table}
\begin{tabular}{c c c} \hline \hline
**Database** & **Type of Information** & **Variables** \\ \hline \multirow{4}{*}{National Institute of Statistics database} & \multirow{2}{*}{Vector} & Neighbourhoods \\ \cline{3-3}  & & Districts \\ \cline{3-3}  & & Census Tracts \\ \cline{2-3}  & \multirow{2}{*}{Numerical} & Annual net household income at district and census tracts level \\ \cline{3-3}  & & tracts level \\ \hline \hline \end{tabular}
\end{table} 
Table 2: _Cont._  
Figure 3: Diagram of data processing. \[CO_{2,avg}=\frac{\sum_{i=1}^{n}CO_{2,i}\cdot A_{i}}{\sum_{i=1}^{n}A_{i}} \tag{2}\]  
where \(EP_{nr,avg}\) is the average weighted non-renewable energy consumption of the building (kWh/m\({}^{2}\)-year); \(CO_{2,avg}\) is the average CO\({}_{2}\) emissions of the building (kgCO\({}_{2}\)/m\({}^{2}\)-year); \(A_{i}\) is the area of dwelling \(i\) (m\({}^{2}\)); \(EP_{nr,i}\) is the average consumption of each dwelling (kWh/m\({}^{2}\)-year); \(CO_{2,i}\) is the average CO\({}_{2}\) emission of each dwelling (kgCO\({}_{2}\)/m\({}^{2}\)-year); and \(n\) is the number of dwellings assessed per building block. The Energy Expenditure to Income Ratio (EEIR) is the monthly percentage of income used to pay for energy for air-conditioning in a dwelling. The EPC database contains the values of the expected energy demand of non-renewable energy consumption (\(EP_{nr}\)) for each dwelling. This value was used to calculate the currency value of the consumption. The currency value of the Energy Expenditure (EE) is obtained using the methodology proposed by [PERSON] et al. [37] (Equations (3) and (4)). \[EE_{i}=VAT\cdot(EEBT_{i}+EEBT_{i}\cdot STE) \tag{3}\]  
\[EEBT=(EP_{nr,i}\cdot\text{EP}\cdot A_{i})+\text{CP}+\text{ER} \tag{4}\]  
where VAT (Value Added Tax) corresponds to 1.21; \(STE\) is the Special Tax on Electricity set at 3.8% [38]. \(EEBT\) is the Energy Expenditure Before Taxes and is calculated by Equation (4). \(EP_{nr,i}\) is the expected energy consumption demand of non-renewable energy of each property; EP is the net price of domestic electricity (which for 2021 is set at 0.162 \(\text{\textcelsius}\)/kWh [39]); \(A_{i}\) corresponds to the area of the dwelling \(i\) in m\({}^{2}\); ER is the equipment rental (this fixed cost for a simple single-phase meter corresponds to 0.54 \(\text{\textcelsius}\)/month [40]); CP is the cost associated with the contracted power and is calculated with Equation (5) (assuming a typical contracted power of 4.60 kW). \[CP=0.136712\ \frac{\text{\textcelsius}}{Kw}\ day\cdot 365\ days\cdot 4.60\ kW \tag{5}\]  
The EEIR indicator is used to assess energy vulnerability and is calculated using Equation (6). \[EEIR=\frac{EE_{i}}{AI_{i}} \tag{6}\]  
where \(EE_{i}\) is the energy expenditure of the dwelling \(i\) and \(AI_{i}\) is the annual income per household of the dwelling \(i\). Based on the results obtained, the 2M indicator is calculated. This indicator is one of the 4 indicators proposed by the EU Energy Poverty Observatory and adopted by the ENPE 2019-2024 [24] to estimate energy poverty. The 2M indicator measures a dwelling's disproportionate expenditure on energy services. It is calculated as the percentage of dwellings whose energy expenditure is more than twice the national median [24]. The calculation of the 2M indicator is derived from the EEIR. The reference value of 2M is twice the national median established annually. The 2M is a variable reference value and depends on the aggregated energy behavior of the country. In Spain, this value corresponds to 8.8-9% for 2021 [41].