Temperature and Residential Electricity Demand for Heating and Cooling in G7 Economies: A Method of Moments Panel Quantile Regression Approach

The global energy system is highly vulnerable to climate variability and change. This results in a vast range of impacts on the energy demand sector and production and supply channels. This article aims to estimate the impacts of variables such as heating and cooling temperatures, income, population, and price on residential electricity demand in G7 countries. Methodologically, this study uses the second-generation panel unit root and cointegration approaches (which are robust in the presence of cross-sectional dependence), a panel fixed effects model with Driscoll– Kraay standard errors, and a novel method of moments quantile regression (MM-QR) to determine long-run elasticities. The results suggest that the residential electricity demand of G7 countries is statistically and positively responsive to cold days rather than hot days. This study also presents some policy-relevant issues based on the results.


Introduction
The global mean temperature has increased by approximately 1 degree Celsius ( • C) in the last century; it could increase a further 1.8 to 4 • C within this century, based on how greenhouse gas (GHG) emissions are handled [1]. Global warming will significantly impact energy demand, which could account for a significant share of the total economic burden due to climate change [2][3][4][5]. Conversely, the energy sector's GHG emissions account for a significant portion of global GHG emissions [1,6]. Consequently, energy demand affects climate change on the one hand, and on the other hand, climate change and policy affect energy demand. This study aims to investigate the effects of temperature variations on energy demand with a focus on electricity.
The temperature-electricity nexus has been studied using various econometric models [4,5,7,8]. According to theory, demand for cooling processes rises once the temperature exceeds a specific threshold; conversely, users may demand electricity for heating, and its demand grows once the temperature drops below a specific threshold [2,4]. As a result, a theoretical U-shaped link exists between electricity demand and temperature, and electricity demand responds asymmetrically to temperature variations [2,4]. Users utilize heating and cooling systems to maintain a comfortable temperature in their residences, directly impacting electricity demand [4,5,7]. Choices made by individuals directly influence residential electricity demand [3,7,9]. Hence, the climate sensitivity of energy demand may be readily demonstrated in this sector following the feedback mechanism.
The degree-day temperature measurement method has been proposed in recent studies because of the properties of the temperature-electricity nexus. Degree days are founded and b is the threshold temperature. Regressing electricity demand on these temperature variation indicators allows researchers to analyze the sensitivity of electricity demand to climate change. These indicators have been used by recent studies investigating the temperature-electricity demand nexus; see [4,5,7].
Many studies have analyzed the various sources of energy demand sensitivity to temperature within specific conditions. It is common for these studies to include as many socioeconomic and geographic variables as feasible. Micro-perspectives help evaluate policy initiatives or analyze the energy demand sensitivity to temperature variations in a single country or region. However, this study focuses on cross-country analysis. Cross-country data on variables such as energy demand patterns, technology, economic conditions, and climates are more comprehensive and provide a basis for more exhaustive and robust analysis and decision-making. Thus, estimated relationships using such data provide a basis for a robust projection of climate and economic conditions. To comprehensively understand climate change's impacts, it is essential to determine how much energy demand is affected by temperature variations.
The primary aim of this study is to determine the temperature sensitivity of G7 residential electricity demand. Due to earlier studies demonstrating that energy demands in the service and manufacturing sectors are weakly affected by temperature variations, we focus on residential energy demand; see [9,15]. We extend the current literature by incorporating theoretical developments of previous studies and introducing some novel aspects. Heating and cooling degree days replace traditional methods for assessing the energy demand impact of temperature variations. Additional factors that could affect temperature sensitivity include income, population, and electricity prices.
As we have a sufficiently large number of data points, we can more confidently estimate the relationships between variables. The G7 countries constitute the world's biggest economies, taking up about 40% of the global economy, consuming around 30% of global energy, and producing about 25% of global energy-related CO 2 emissions (including 2.7 Gt from electricity). The IEA [6] projects an increase of about 80% in G7 electricity demand by the year 2050. This has enormous implications for the global energy system decarbonization agenda. Thus, achieving net-zero emissions by 2050 will be impossible without decarbonizing energy. Current literature using panel unit root and cointegration to investigate the long-run nexus between energy demand (e.g., electricity demand) and climate change (e.g., temperature) is dominated by the first-generation panel unit root and cointegration approaches of Pedroni [16,17] and Kao [18]; see [8]. There is a dearth of studies using the secondgeneration panel unit root and cointegration approaches. A key differentiating factor between these two approaches is that the first generation is not robust in the presence of cross-sectional dependence. A generation panel cointegration test based on error correction was developed by Westerlund [19] and is robust even when the CSD is present. Thus, without accounting for cross-sectional dependence, estimates from existing studies are likely spurious. The Westerlund [19] panel cointegration test is used to investigate the existence of a long-run relationship between residential electricity demand and its drivers. A fixed effects model with Driscoll-Kraay standard errors [20] and the novel method of moments quantile regression (MM-QR) [21] are used to determine long-run elasticities in this study.
A review of the relevant empirical literature is provided in the next section. Using the concept of heating degree days, we illustrate how we model the electricity demand drivers and present our data in Section 3. The results and discussion of the heating and cooling effects, and the results of covariates, are presented in Section 4. Section 5 brings the study to a close by outlining the study's policy implications and limitations.

Review of Related Empirical Literature
A critical yet complex subject is how climate change affects people's lives and the economy. Several studies have been conducted to answer this question in the last few years. An in-depth review of weather data, climate models, and their application to the social sciences is provided by Auffhammer [22]. A summary and synthesis of recent innovations in theoretical and empirical methodologies employed to analyze the socioeconomic impacts of climate change is provided by Hsiang [23]. More specifically, this study is related to recent research on the effects of temperature on energy demand, which has focused on the residential sector. Research has shown that residential electricity demand is more responsive to temperature variations than the industrial sector; see [9,15]. The demand for space cooling in the residential sector is driven by the fact that consumers desire stable comfort conditions [7]. The energy-temperature nexus is commonly considered a hypothetical U-shape in literature [4,5]. The threshold is the temperature at which heating and cooling are equally balanced. Increased cooling demand is expected if the temperature rises over the threshold, whereas increased heating demand is expected if the temperature falls below the threshold.
The HDD and CDD are commonly used to measure temperature in the literature. Although the HDD represents the cumulative degrees below the threshold temperature across specified time intervals (e.g., hourly, daily, monthly, among others), the CDD represents the cumulative degrees above the threshold temperature [3]. Several studies have extensively utilized these measures; see [2,4,5,7,[24][25][26]. These studies commonly set a threshold temperature of 18.3 • C (or 65 • F). Some studies argue against the 18.3 • C temperature threshold. According to Kaufmann et al. [27], the 18.3 • C threshold biases statistical estimates in the context of global warming. Other research suggests that the thresholds should be based on building characteristics and other non-temperature parameters [28,29].
Tol et al. [2] studied the impact of temperature changes on energy use in 62 countries from 1978 to 2002. Their results showed that electricity demand declines with increasing temperatures due to a reduction in the demand for energy for heating, even though the rate of reduction decreases as temperature increases. Additionally, they found that temperature did not affect the demand for cooling energy. Li et al. [5] estimated the climatic impacts on residential energy consumption in China from 1985 to 2000. Their results suggested a warmer summer would have a more significant effect than a colder winter, meaning an increase in annual electricity usage due to global warming. Yating et al. [30] used a fixed effects panel model of Chinese households to investigate the effects of climate change on electricity demand. Their results showed that, on cold days, an increase in temperatures of 1 • C lowered electricity consumption by 2.8%, and on warm days, an increase in temperature of 1 • C increased electricity consumption by 14.5%. Trend analysis and time series data from 1975 to 2013 were used by Thornton et al. [31] to examine the influence of temperature on Great Britain's electricity demand variability and extremes. Their results showed that mean electricity demand exhibited low-frequency variability and was linked primarily to the influence of variable socioeconomic factors. However, they also showed that electricity demand and temperature had a high negative correlation (r = −0.90) when the variability of socioeconomic factors was removed.
One area of research examines how climatic influences affect energy usage in different regions. Emodi et al. [7] used an autoregressive distributed lag (ARDL) model to investigate the short-and long-run effects of temperature variations due to climate change on energy demand in six Australian states and one territory. Future climate change impact on electricity demand was also investigated in their study. Their results projected that the summer peak demand for electricity would rise, whereas the demand in the winter was projected to rise because of increasing temperature. Using a panel data model and California residents between 2003 and 2006, Aroonruengsawat and Auffhammer [32] analyzed how household electricity usage differed among climate zones. Their findings showed that electricity demand rises substantially across climate zones as temperatures rise. A similar study by Pilli-Sihvola et al. [33] investigated the impacts of a warmer climate on heating and cooling demand in five European countries using an econometric multivariate regression model. According to their findings, there is a predominant reduction in heating due to climate change in Central and Northern Europe, and as a result, electricity costs will decrease. In Southern Europe, climate change and the resulting increase in cooling and electricity demand exceeds the decline in heating demand. Consequently, costs also increase.
Another strand of the literature has looked at the nexus between energy demand and temperature with the various seasons. Several models, including log-linear, semiparametric, and non-parametric models, have been used to analyze the energy consumption effects of climate change. According to Du et al. [4], residential electricity usage is more likely to increase in hot weather than in cold weather due to climate change. According to Thornton et al. [31], seasonal variations in electricity demand lead to an increased correlation between temperature and electricity demand. Taking annual temperature and demand cycles out of the equation, we get a correlation, r, of 0.60. Temperature and demand are closely linked in winter, with a 1% rise in demand for electricity for every 1 • C decrease in daily temperature.
Accounting for socioeconomic factors, the marginal effect of CDD on electricity consumption first increases with an increase in income, as shown by Du et al. [4]. However, when income increases further, the marginal increase curve turns flat. Yating et al. [30] showed that as income rises, the sensitivity of households to extreme weather conditions does not change for hotter summer days, but it does rise for colder winter days. Panel cointegration was employed by Narayan et al. [8] to analyze the impact of income and price on electricity demand in the G7 countries. Results from the G7 countries revealed that income and price are critical factors in the demand for electricity caused by temperature. Additionally, Emodi et al. [7] found that in some Australian states, there was a significant relationship between temperature-induced electricity demand and income, price, and population. Table A1 in Appendix A summarizes the previous studies on the relationship between climate change (with a focus on temperature), electricity demand, and other key influencing variables. We also highlight key methodological areas of concern that have been treated or are yet to be treated in existing studies and report the key findings.
Most of these studies have focused on the demand for electricity in the general framework of household production theory, in which a household purchases a composite energy commodity by combining capital assets and electricity. Consequently, purchased electricity and appliance capital stock determine the output of a composite energy commodity.
Barring data constraints, Narayan et al. [8] suggested accounting for other factors such as electricity price (either own price, substitute energy source, or both), household income, or any other variables that may affect household preferences, including temperature or the cost of household appliances [8]. There is still a dearth of studies accounting for these explanatory variables. Electricity demand or energy consumption has been modelled as a function of a single explanatory variable or two variables, such as income or temperature; see [8]. Only a few studies have examined the relationship between electricity demand and variables such as temperature, income, and the cost of producing the energy itself; see [7].
The present study adopts a second-generation panel unit root and cointegration framework that considers the time-series and cross-sectional dependence properties of the data. Recently, researchers have used a panel unit root and cointegration framework to investigate the long-run relationship between energy demand (including electricity) and variables such as temperature [8]. Still, there is a dearth of empirical evidence accounting for cross-sectional dependence in estimates of the residential electricity demand equation. Some studies have estimated household electricity income and price elasticity in a panel design by pooling cross-sectional and time-series data from G7 countries. The findings from these studies are spurious because these studies did not initially check if the panel data were stationary and cross-sectionally dependent using the second-generation panel unit root and cointegration tests. Residential electricity demand and its drivers were examined using the panel cointegration test of Westerlund [19], which allows for cross-sectional dependence. Long-run elasticities were estimated by using a combination of fixed effects regression with Driscoll-Kraay (D-K) standard errors [20] and a novel method of moments quantile regression (MM-QR) [21] estimation techniques.
The G7 countries were chosen for a few reasons. In 2020, G7 member countries constituted the world's biggest economies, taking up about 40% of the global economy, consuming around 30% of global energy, and producing about 25% of global energy-related CO2 emissions (including 2.7 Gt from electricity) (G7 member countries include Canada, France, Germany, Italy, Japan, the United Kingdom, the United States (plus the European Union)). The IEA projects an increase in G7 electricity demand of over 80%, a sharp departure from the recent decade of stagnation [6]. This increase is linked to the rapid electrification of space heating, mobility, and industrial processes. This would increase the share of electricity in the final energy demand from about its current 22% to approximately 55% by 2050. Electricity decarbonization is essential to achieving net zero emissions by 2050 [34,35]. To achieve net-zero emissions, the G7 countries have agreed on policies and targets that aim to phase out or reduce coal-fired electricity while growing renewables, hydrogen, and carbon capture technologies. G7 country governments have committed more than $500 billion to renewable energy to help countries recover from the COVID-19 pandemic, 17% of which has been allocated to the electricity sector.
Furthermore, Emodi et al. [7] note that a shift will occur such that cooling demand will increase in temperate zones by the end of the century, whereas heating demand will steadily decline. This point suggests that more frequent peaks in demand for cooling services, such as electricity, should be expected. Consumers may switch to electricity, which is more efficient over time for heating. During the summer and winter, the electricity demand will be at its highest. Fossil fuel power stations have helped meet some of these seasonal peak demands [36]. One of the primary causes of climate change is the widespread usage of fossil fuels. As the demand for thermal comfort rises, so does the amount of money people are willing to spend, despite the measures in place to address climate change [37].

Selection of the Variables and Hypotheses
Identifying the key factors influencing electricity consumption is crucial before unit root testing. This type of identification guarantees consistency between theory and the research literature. There are two distinct types of electricity consumption in a building: baseload and weather-dependent [7]. In contrast to baseload consumption, the litera-ture shows that weather-dependent consumption is more prevalent. Furthermore, because consumers might not switch out their appliance stock during the year, baseload consumption may stay constant; however, temperature changes significantly impact electricity consumption.
Using the degree-day methods mentioned in Section 1 and illustrated in Equations (2) and (3) below, it is possible to determine the impact of temperature changes on electricity demand. This approach has been widely used in literature that examines how climate change affects energy demand [2,4,5,7,[24][25][26]33]. These studies lead us to exclude other weather factors from the final model, including rainfall, relative humidity, and wind speed. In addition, recent research indicates that rainfall has a negligible effect on energy use; see [7,9].
Socioeconomic factors such as population are crucial determinants in forecasting energy consumption changes. According to Ahmed et al. [38], total energy consumption would change in line with a population change, even if per capita energy consumption remained constant over time. Studies have revealed a positive elastic relationship between income and energy consumption in terms of income level. A change in income is linked to an increase in energy consumption, suggesting that energy is regarded as a normal good [4,8,30]. Additionally, some studies discover a co-integration between national energy consumption and gross domestic product (GDP); see [39,40].
As price impacts general energy and electricity policies, price is a critical indicator in energy demand assessment. According to Narayan et al. [8], there is a long-term relationship between total electricity demand and price, and this relationship is price elastic. These studies support the selection of the chosen variables-GDP, population, price, CDD, and HDD-as significant drivers of electricity demand in the G7 countries.
The functional relationship and hypotheses are presented next. To guide the empirical investigation, the following equation was developed based on the justification for the selection of variables: where ELD represents the total annual residential electricity demand in petajoules, TMP represents the temperature, GDP represents the income, POP represents the population, and PRC represents the domestic electricity price. ϕ 0 is the intercept of the functional relationship and ϕ 1 , . . . , ϕ 4 are the explanatory variable coefficients that explain the various effects of the variables on ELD. The functional relationship also includes the idiosyncratic error term ε, the country index i, and the time index t as additional parameters. The ln sign implies that all variables have been specified in natural logarithmic form. Furthermore, we assume strict exogeneity across the model variables.
The first step was identifying an appropriate temperature measurement, as there is a non-linear relationship between temperature and energy demand [2,4]. According to previous research, the relationship between climate change and electricity demand is a U-shaped curve. Li et al. [5] indicated that the temperature-response curve of household electricity consumption is flat when the temperature range is 18.3 • C, and electricity consumptions increase with deviations from this comfort zone. For this investigation, we followed existing studies [2,7,26] to set the temperature threshold at 18.3 • C and the indicators of HDD and CDD were constructed as follows: where the subscripts i, t, and h denote country, year, and hour, respectively. N represents the total number of six hours in a year. Temp i,t,h represents the actual temperature recorded every six hours in degrees Celsius. The HDD or CDD indicators capture the demand for electricity needed to heat or cool buildings. The impacts of HDD and CDD are generally found to be asymmetrical [4]. Thus, the DD in Equation (1) is expanded to account for the heating and cooling effects of temperature, as formulated in Equations (2) and (3). This step yields the following equations: where HDD in Equation (2) denotes heating degree days or the heating effect and CDD in Equation (3) denotes cooling degree days or the cooling effect.

Data Sources
The World Energy Balances database of the International Energy Agency [41] provided information on electricity demand. Total home electricity demand measured in petajoules (PJ) was the variable used. For G7 countries, IEA data on residential electricity demand was available from 1971 to 2019. The King Abdullah Petroleum Studies and Research Center (KAPSARC) database provided HDD and CDD data [42]. The degree-day data were obtained by KAPSARC, utilizing satellite gridded datasets. The database provides population-weighted degree days for 147 countries from 1948 to 2013 based on multiple thermal comfort indices at different threshold temperatures. The database was primarily created to examine the cross-country impact of weather on energy consumption; for a detailed description, see [42]. Following previous research, we chose 18.3 • C as the temperature threshold for deriving the HDD and CDD data. Thus, HDD and CDD were derived from the plain temperature at 2 m elevation at a temperature reference point of 18.3 • C and a 6-hour frequency. However, only data up to 2013 were available. This study employed the extrapolation method to extend data through 2015 to increase the number of observations. Several recent studies have analyzed temperature-electricity demand using KAPSARC data; see [43][44][45]. The Penn World Table version 10.0 provided information on real income or real GDP [46]. The proxy variable chosen was the expenditure-side real GDP at chained PPPs (in millions of 2017 U.S. dollars). The population data were obtained from the FAO's statistical database. Data on domestic electricity (own price) are IEA country data for domestic electricity prices excluding taxes (in US cents per kilowatt-hour) collected from the database of the UK Department of Business, Energy, and Industrial Services [47]. The database contains price information for France, Germany, Italy, Japan, and the United Kingdom from 1979 to 2020. However, price information for North American countries (Canada and the United States) was unavailable before 1990.
For this analysis, a balanced panel of G7 countries covering the period 1990-2015 was collected (26 years and 182 observations). Table 1 shows the variable definitions and data sources. Descriptive statistics of variables are presented in Table 2.

Estimation Methods
Preliminary steps were taken to identify the properties of the variables employed and confirm the existence of singularities, which, if ignored, could result in inaccurate inferences. Table 3 presents the crucial preliminary tests carried out in this study. Next, this study followed the methodological approach presented in Figure 1.

Normality Test
Normality tests were used to determine the distribution of variables, including the skewness/kurtosis [50] and Shapiro-Wilk tests [49]. The results of the normality tests are shown in Table 4.

Cross-Sectional Dependence Test
Factors driving variations in the G7's socio-econo-political and environmental conditions probably have cross-sectional dependencies because of the strong links between the G7 countries. As a result, we used cross-section dependence (CSD) methods to identify the most suitable methodological techniques. This study relied on the CSD test results to decide which panel data estimation technique to employ. It is likely for a study to yield spurious results if the CSD test is not conducted [55]. This study conducted a robustness review using the following three CSD tests to ensure that none of these complications occurred: the Breusch and Pagan [51] LM technique, the Pesaran [52] CSD test statistic, and the Pesaran [53] scaled LM CSD technique. As the temporal dimension (T) of the dataset exceeded its cross-sectional dimension (N), this study focused on the Breusch and Pagan [51] LM technique and the Pesaran-scaled LM test [53]. The CSD test approach is presented in Equation (6).

Normality Test
Normality tests were used to determine the distribution of variables, including the skewness/kurtosis [50] and Shapiro-Wilk tests [49]. The results of the normality tests are shown in Table 4.

Cross-Sectional Dependence Test
Factors driving variations in the G7's socio-econo-political and environmental conditions probably have cross-sectional dependencies because of the strong links between the G7 countries. As a result, we used cross-section dependence (CSD) methods to identify the most suitable methodological techniques. This study relied on the CSD test results to decide which panel data estimation technique to employ. It is likely for a study to yield spurious results if the CSD test is not conducted [55]. This study conducted a robustness review using the following three CSD tests to ensure that none of these complications occurred: the Breusch and Pagan [51] LM technique, the Pesaran [52] CSD test statistic, and the Pesaran [53] scaled LM CSD technique. As the temporal dimension (T) of the dataset exceeded its cross-sectional dimension (N), this study focused on the Breusch and Pagan [51] LM technique and the Pesaran-scaled LM test [53]. The CSD test approach is presented in Equation (6).
where T represents the study period (1990-2015; 26 years), N represents the cross-sections (7 countries) andρ ij represents the correlation of errors between cross sections. The null hypothesis for the CSD statistic was that there was no cross-sectional dependence.

Unit Root Test
To determine the unit root properties of the variables, we applied the panel unit root test developed by Pesaran [52], which accounts for CSD. This approach extends the Dickey-Fuller regression to address CSD. The cross-sectionally augmented Dickey-Fuller (CADF) test is estimated as follows: where y t represents the average value of y at time t across N observations. The CADF equation is computed for each cross-sectional unit, after which the average of all the cross-sections is determined, and the test statistic that is obtained is computed as follows: where CADF i is the statistic obtained from the CADF regression presented in Equation (7).

Cointegration Tests
This study employed the error correction-based cointegration test developed by Westerlund [19], as follows: ω i in Equation (9) is the coefficient of the error correction term, which indicates the speed of correction towards equilibrium, and ∆ is the first difference operator. Equation (9) yields four test statistics, as follows: where G t in Equation (10) and G a in Equation (11) test for cointegration in at least one cross-sectional unit. P t in Equation (12) and P a in Equation (13) test for cointegration in the whole panel. The null hypothesis states that no cointegration exists. Thus, this study will reject the null hypothesis if one or both panel statistics show a statistically significant result.

Parameter Estimates
This study first employed the fixed effects regressions with Driscoll-Kraay (DK) [20] standard errors to produce baseline estimates for Equations (2) and (3), which are robust to cross-sectional and temporal dependence. Furthermore, this study employs the Mundlak [54] alternative to the Hausman [56] specification test to determine the suitability of the random effects (RE) or fixed effects. The Mundlak approach, as opposed to the Hausman approach, can be utilized in situations where the errors are heteroskedastic or exhibit an intragroup correlation; for more information, see Wooldridge [57] and Pinzon [58]. The OLS/weighted least squares and fixed effects regression are used in the fixed effects D-K regression approach, which also computes spatial correlation consistent standard errors for linear panel models [59]. The standard errors of the coefficient's estimates are adjusted using these estimators to account for any dependence [60]. The D-K regression technique can only model the conditional mean of the dependent variable and is, thus, limited. This study employed the method of moments quantile regression (MM-QR), a technique that incorporates fixed effects in panel quantile models, developed by Machado and Silva [21]. This study aimed to analyze other elements of the conditional distribution of electricity demand (ELD). The effects of temperature, income, population, and prices on the lower, median, and upper distributions of ELD in the G7 countries were analyzed with the help of the MM-QR estimator. In the same vein as existing panel quantile regression approaches, the MM-QR estimator generates reliable and valid estimates despite the absence of strict distributional assumptions [61]. The MM-QR technique, on the other hand, produces regression quantiles based on the conditional location-scale shift model. This makes it possible for individual impacts to influence the distribution as a whole [62,63]. As a result, MM-QR is more reliable and has emerged as the leading quantile regression technique in the most current research [62,63]. The following is a general specification for the conditional quantile Q Y (τ|X it ) estimation of the location-scale variant model: X it is a vector of explanatory variables (i.e., degree days (HDD and CDD), real income (GDP), population (POP), and domestic electricity price (PRC)). Q Y (τ|X it ) is the quantile distribution of the dependent variable (ELD), conditional on the location of the explanatory variable (X it ). α i (τ) = α i + δ i q(τ) is the scalar coefficient of the quantile-τ fixed effect for individual i, or the distributional effect at τ. q(τ) is the τ-th quantile resulting from the following optimization function: where the following expression specifies the check-function, ρ τ (A) = (τ − 1)AI{A ≤ 0} + τ AI{A > 0}. From the MM-QR model in Equation (15) and the functional relationship in Equations (2) and (3), this study specifies the following quantile-based approach for empirical investigation:

Empirical Results and Discussion
This section focuses on the empirical results of this study, starting with preliminary tests and then presenting the model estimation results. Table 4 below shows the results from the normal distribution tests. The natural logarithm of electricity demand (lnELD) was skewed, as shown in the results of the normal distribution tests. This study rejected the null hypothesis that the variables were normally distributed for the sampled countries during the study period, based on D'Agostino and Belanger's [50] combined skewness-kurtosis test. Additionally, the Shapiro-Wilk [49] test supported the rejection of normality in variable distributions.

Normality Test
This study focused on the distribution of the dependent variable, ELD. The distribution of ELD is shown in Figure 2 using histogram and kernel density plots. Figure 2 shows that the ELD has a skewed and peaked distribution markedly different from the normal distribution. Belanger's [50] combined skewness-kurtosis test. Additionally, the Shapiro-Wilk [49] test supported the rejection of normality in variable distributions. This study focused on the distribution of the dependent variable, ELD. The distribution of ELD is shown in Figure 2 using histogram and kernel density plots. Figure 2 shows that the ELD has a skewed and peaked distribution markedly different from the normal distribution. In this study, the T is greater than the N dimension; thus, we use the LM test for CSD. Furthermore, this study follows recent studies by including the Pesaran [52] test statistic and the Pesaran [53] LM CSD test [see [55,64]]. Applying the Breusch-Pagan LM and Pesaran CSD tests for the panel data (Table 5) showed the existence of CSD in all model variables. The CSD tests suggested that the countries chosen for this research have similar traits and shocks [65].

Unit Root Test
This sub-section applied both a first-generation panel unit root test [66] and a secondgeneration panel unit root test [52] to check the unit root properties and order of integration of the model variables. We focused on Pesaran's second-generation panel unit root test [52], CIPS. Table 6 below shows the results. The CIPS test results indicated that the variables lnHDD and lnCDD, with and without the trend, were stationary at level I(0). On

Cross-Sectional Dependence Test
When T > N, De Hoyos & Sarafidis [64] recommend using the Breusch and Pagan's [51] Lagrange Multiplier (LM) test. In this study, the T is greater than the N dimension; thus, we use the LM test for CSD. Furthermore, this study follows recent studies by including the Pesaran [52] test statistic and the Pesaran [53] LM CSD test [see [55,64]]. Applying the Breusch-Pagan LM and Pesaran CSD tests for the panel data (Table 5) showed the existence of CSD in all model variables. The CSD tests suggested that the countries chosen for this research have similar traits and shocks [65].

Unit Root Test
This sub-section applied both a first-generation panel unit root test [66] and a secondgeneration panel unit root test [52] to check the unit root properties and order of integration of the model variables. We focused on Pesaran's second-generation panel unit root test [52], CIPS. Table 6 below shows the results. The CIPS test results indicated that the variables lnHDD and lnCDD, with and without the trend, were stationary at level I(0). On the contrary, the variable lnPOP was stationary at levels only without the trend, whereas the variables lnELD, lnGDP, and lnPRC, with and without the trend, were stationary at first difference I(1). However, all variables are I(1).

Cointegration Test
A model that includes I(1) variables suggests that cointegration between these variables should be tested. As a result, the panel cointegration test developed by Westerlund [19] was used in the investigation. The results of the cointegration test are shown in Table 7 below.  The results from Table 7 indicate that we could reject the null hypothesis and conclude that cointegration exists among the model variables based on the statistical significance of the G t and P t estimates.

Model Selection Tests
This study employed the Mundlak approach to compare the appropriateness between the random and fixed effects model. The null hypothesis is that the there is no systematic difference between coefficients, making the random effects model the more suitable estimator [63]. The result in Table 8 suggests rejecting the null hypothesis, indicating that the fixed effects model is appropriate. Furthermore, Equations (4) and (5) can best be estimated using the fixed effects model (FE-DK) based on the Mundlak test.

Empirical Results from Panel Regression Techniques
The model results are presented in Tables 9 and 10. Results in Table 9 assess the heating effect, whereas those in Table 10 assess the cooling effect. The fixed effects D-K in column 1 present the estimates of the mean effect. The MM-QR in columns 2-6 presents the estimates for distributional heterogeneity in the effects of both HDD and CDD in G7 countries. The estimated quantiles (Q.) are the 10th, 25th, 50th (median), 75th, and 90th quantiles presented in both Tables 9 and 10.  Note: Standard errors in parentheses. ***, **, * indicate significance at 1%, 5%, and 10% levels, respectively. Source: Authors' computations and compilation. Table 9 represents the model results of the fixed effects D-K regression and MM-QR for heating effects on electricity demand. Based on the fixed effects D-K regression, an increase in the HDD positively impacted electricity demand. More specifically, a 1% increase in HDD caused a 0.26% increase in electricity demand in G7 countries (statistically significant at a 5% level). Furthermore, based on the MM-QR regression, an increase in the HDD positively impacted electricity demand. Furthermore, the results across the quantile indicated that a 1% increase in the HDD caused electricity demand to increase by 0.24% in the 25th quantile, 0.37% in the 50th quantile, 0.28% in the 75th quantile, 0.3% in the 90th quantile (statistically significant at the 5% level). The result also shows a positive but statistically insignificant impact of HDD on electricity demand at the 10th quantile. Similar to existing studies (see [2,7,67]), these results showed that HDD significantly increased electricity demand in the G7.

Cooling Effect and Electricity Demand
Climate change is expected to lead to an increase in cooling demand. Although one of our stated objectives was to estimate the cooling effect, Table 10 shows zero evidence of a significant cooling effect on electricity demand. Even when we estimated the cooling effect separately from the heating effect, the outcome was the same. However, this does not rule out the possibility of a cooling impact. Our data set covers a wide geographic area, encompassing countries on multiple continents. It may have been difficult to detect the cooling effect based on the current data because cooling is recent in the residential sector. Data that spans many years may be necessary to detect any cooling effects. This result is consistent with the findings of Tol et al. [2], who found no statistically significant cooling effect for many countries and years. However, these results differed from Emodi et al. [7], who found a significant positive cooling effect in summer and spring across Australian states.

Effects of Covariates
Column 1 in Tables 9 and 10 represents the model results of the fixed effects D-K and MM-QR regression for cooling effects on electricity demand. Based on the fixed effects D-K regression, an increase in income positively impacted electricity demand. More specifically, a 1% increase in income caused a 0.44% increase in electricity demand in G7 countries (statistically significant at the 1% level). Furthermore, based on the MM-QR regression, an increase in income caused an increase in electricity demand. Furthermore, the results across the quantiles indicated that a 1% increase in income caused electricity demand to increase between a low of 0.39% (Q.90th in Table 10) and a high of 0.49% (Q.10th in Table 10). Thus, as recent studies [2,7,8,63] also concluded, an increase in income leads to increased electricity demand.
For population, the fixed effects D-K regression results in column 1 of Tables 9 and 10 indicate that an increase in population positively impacts electricity demand. More specifically, a 1% increase in the population caused approximately a 0.53% increase in electricity demand in G7 countries (statistically significant at the 1% level). Furthermore, based on the MM-QR regression, an increase in income caused an increase in electricity demand; however, the results were insignificant in all the quantiles. The variable population positively affected electricity demand in the 10th, 25th, 50th, and 75th quantiles of both Tables 9 and 10. The result was statistically significant at the 1% level and 5% level in the Q.75th and positive but not statistically significant (at the 5% level) in the Q.90th. Thus, as concluded by related studies [68,69], an increase in the population increased electricity demand. However, this result differs from recent studies, which found a negative effect of population on electricity demand [7,70].
For the price elasticity of electricity demand, the D-K regression results in column 1 of Tables 9 and 10 indicate that an increase in population causes a slight negative impact on electricity demand. This result implies that a 1% increase in the domestic electricity price causes approximately 0.08 (Table 9) and 0.06% (Table 10) decreases in electricity demand in G7 countries. However, although the result in Table 9 was statistically significant at the 5% level, the result in Table 10 was only statistically significant at the 10% level. Furthermore, results based on the MM-QR regression indicated mixed effects across quantiles. In the 10th, 25th, and 50th quantiles, increases in the domestic electricity price caused a statistically negative effect on electricity demand (at 1% and 5% levels). However, in the 75th and 90th quantiles, an increase in domestic electricity price caused a negative but statistically insignificant effect (at any conventional level) on electricity demand. Furthermore, in Table 5, the effects on domestic electricity demand in the 10th, 25th, and 50th quantiles remain statistically negative at the 5% level. At the same time, they are statistically insignificant negative and positive in the 75th and 90th quantiles, respectively. Thus, households in G7 countries responded slightly proportionately to changes in the electricity price. Consequently, as with similar studies [8,66], increased electricity prices caused a decrease in electricity demand. However, this differs from Emodi et al. [7], who found mixed results across Australian states and seasons.
The graphical results of the MM-QR regression approach are presented in Figures 3 and 4. The gray regions represent the 95% confidence intervals for the MM-QR regression estimates. The y-axis displays the elasticities of the explanatory variables, whereas the quantiles are displayed on the x-axis. 75th and 90th quantiles, an increase in domestic electricity price caused a negative but statistically insignificant effect (at any conventional level) on electricity demand. Furthermore, in Table 5, the effects on domestic electricity demand in the 10th, 25th, and 50th quantiles remain statistically negative at the 5% level. At the same time, they are statistically insignificant negative and positive in the 75th and 90th quantiles, respectively. Thus, households in G7 countries responded slightly proportionately to changes in the electricity price. Consequently, as with similar studies [8,66], increased electricity prices caused a decrease in electricity demand. However, this differs from Emodi et al. [7], who found mixed results across Australian states and seasons.
The graphical results of the MM-QR regression approach are presented in Figures 3  and 4. The gray regions represent the 95% confidence intervals for the MM-QR regression estimates. The y-axis displays the elasticities of the explanatory variables, whereas the quantiles are displayed on the x-axis.  Table 9. Source: Authors' diagram. Figure 3. Quantile regression plots for estimates in Table 9. Source: Authors' diagram.  Table 10. Source: Authors' diagram.

Further Discussion of the Results
Temperature below the 18.3 °C threshold induces residential electricity consumers to demand electricity for their heating needs, leading to the heating effect and the derivation  Table 10. Source: Authors' diagram.

Further Discussion of the Results
Temperature below the 18.3 • C threshold induces residential electricity consumers to demand electricity for their heating needs, leading to the heating effect and the derivation of the HDD. Conversely, temperatures above the 18.3 • C threshold induce residential electricity consumers to demand electricity for their cooling needs, leading to the cooling effect and the derivation of the CDD. Based on our findings, the HDD had a statistically significant positive effect on electricity demand. On the other hand, the CDD has a statistically nonsignificant positive effect on electricity demand. Also, HDD increased electricity demand in the upper quartile countries, such as the United States and Japan. Thus, the estimated results show that the temperature effects on electricity demand in the G7 countries were driven by heating demand during the sample period. Following Tol et al. [2], we estimated an individual country time series model for each of the G7 countries to investigate the cooling effect. We found that only Japan exhibited a significant cooling effect. This suggests that the cooling effect remained a regional concern.
Tables 9 and 10 show that the signs and significance for most control variables across quantiles are consistent with previous results. The coefficient of GDP was positive and suggested that an increase in income increased electricity demand. This result is consistent with the existing literature. The population coefficient was positive and suggested that an increase in the population increased electricity demand. Utility companies usually respond to an increase in electricity demand by expanding generation capacity to provide adequate electricity [7]. In this regard, the population is an important factor contributing to changes in electricity demand. The findings from Tables 9 and 10 show that, in general, an increase in population is associated with an increase in electricity demand. The price elasticity of electricity demand ranged from a 0.06 to 0.16% reduction in electricity demand. This indicated that residential electricity consumers responded slightly to changes in the electricity price by reducing consumption. As we found a long-run relationship among the variables, an elastic electricity demand suggests that residents make long-term adjustments, such as a higher insulation rate in buildings, energy efficiency improvements, and a change to other fuels or technologies [7]. According to Meier et al. [71], an increase in spending on energy commodities due to changes in the energy price was associated with an increase in household income in British households.

Conclusions, Policy Relevance, and Limitations
The contribution of this study was to employ a second-generation panel unit root and cointegration framework and national-level panel data to investigate the impact of temperature variations on residential electricity consumption in G7 countries. A noteworthy point was that this study accounted for the asymmetric effects of temperature on electricity demand. Thus, this study accounted for both the heating and cooling temperature effects. Furthermore, it accounted for key covariates influencing residential electricity demand, such as income (proxied by GDP), population, and domestic electricity prices.
From a methodological standpoint, we accounted for the distributional heterogeneity of electricity demand using the MM-QR estimator, which does not strictly rely on the assumption of a normal distribution and is appropriate for short data periods. Hence, a significant advantage of the MM-QR estimator is that it allows us to capture the distributional heterogeneity of the electricity at different conditional quantile distributions of temperature and other control variables [21]. Additionally, the MM-QR estimator is useful in situations where the panel data model is embedded with individual effects and when the model possesses endogenous explanatory variables.
The empirical evidence from the panel results leads to the following conclusions about the residential electricity demand of G7 countries: (1) They are positively responsive to cold days rather than hot days. On average, a 1% increase in HDD will increase electricity demand by 0.27%, which is less than proportional. (2) They are income inelastic. On average, a 1% increase in income will increase electricity demand, less than proportionately, by 0.44% (3) They are price inelastic. On average, a 1% increase in own price will decrease electricity demand, less than proportionately, by 0.11%. (4) They are positively responsive to the population.
This kind of electricity demand study is relevant to practical and policy-related measures. Firstly, there is a hypothesized U-shaped relationship between temperature variation and residential electricity demand. At the same time, climate change has been projected to cause warming that will increase cooling demand. However, there is still no consensus in the literature. This study found that the heating effect was the primary driver of the temperature effect on residential electricity demand during the study period. Secondly, consistent and unbiased estimates of income and price elasticities of electricity demand are crucial information for public policy design aimed at energy sector reforms and demand management plans by utility companies. Thirdly, the price elasticity of electricity demand provides crucial information concerning pricing policy effectiveness in promoting efficient energy use. The G7 countries are responsible for a large share of global energy consumption and energy-related CO 2 emissions. The relatively low values of domestic price elasticities imply that deploying only pricing policies to reduce long-run residential electricity demand may not be effective and that, from an environmental standpoint, there is relatively little potential for the G7 countries to reduce residential electricity consumption, and consequently, carbon emissions, using only taxation.
Our results also have implications for energy security, defined as sufficient, affordable, and reliable energy. Energy security risks include the inability of an energy infrastructure system to manage a growing load demand and physical security threats, such as extreme weather events. The use of residential electricity is mainly for heating purposes because the coefficient of the heating degree days was statistically significant. In contrast, the coefficient of cooling degree days was not statistically significant. Recent projections indicate that future temperatures will increase, resulting in hotter summers and warmer winters. This situation is expected to decrease the electricity demand for heating while increasing the electricity demand for cooling. Changes in energy demand will likely affect greenhouse gas emissions, but the net effect will depend on the energy sources used to generate electricity, including alternative energy.
In addition, income and population growth in G7 countries are expected to increase energy demand and pressure current electricity systems. Currently, fossil fuels dominate the energy infrastructure of G7 countries. An increase in the price of electricity had a detrimental impact on its demand and affordability, particularly for quantiles with lower electricity consumption (or countries). In contrast, a price increase did not significantly affect the highest electricity consumers (see 75th and 90th quantiles). Consequently, this could pose a challenge for energy justice because countries with the largest economies consume the most electricity and vice versa. As price elasticity is less than one, the negative coefficient suggests that price may be used to induce a transition to renewable electricity sources, albeit modestly.
These issues underscore the critical need for robust and well-planned policies and investments to enhance the security of electricity systems that provide power to homes and other vital components of the economies. This requires making electricity systems more resilient to the effects of extreme weather and more efficient and flexible by increasing the share of solar and wind power, which is vital for achieving net-zero emissions.
As with most empirical research, this study had limitations. Given the scope of this article, only the HDD and CDD temperature measurements were included. Future research would ideally include more weather/climate-related variables, such as precipitation, relative humidity, and others, to comprehensively investigate climate change effects on the residential sector power demand. In addition, a temperature threshold of 18.3 • C was considered based on its prevalence in the scientific literature. Future research should investigate multiple temperature thresholds as part of their sensitivity analysis for examining the heating and cooling effects of temperature on household power demand. In addition, this study used real GDP as a proxy for income based on a review of the relevant literature and model fit. An alternative income variable, such as per capita income, may be more appropriate for future research.
The methodology employed in this study also presented some limitations. The MM-QR estimator is more restrictive than the traditional quantile regression: first, the MM-QR estimator assumes that the model regressors are strictly exogenous, and second, the estimator, although it accounts for individual fixed effects, does not simultaneously model both individual fixed and time effects [21]. However, as noted by Machado and Silva [21], the additional structure imposed by the estimator is useful in many applied settings. The noteworthy point is that the MM-QR estimator provides an easy way to estimate regression quantiles when using the traditional approach is difficult or impossible. Additionally, we note that the methodological framework applied in this study could be applied to analyze the relationship between temperature and residential electricity demand in countries other than G7, especially in developing countries where electricity demand exhibits significant cross-country heterogeneities [72].
However, future studies on this subject should seek to address these constraints. Despite the limitations, the analysis enabled us to draw significant economic and energy policy conclusions. In this regard, the government should encourage using electric batteries to minimize greenhouse gas emissions and enhance air quality. On the other hand, the European economy must continue to employ green growth strategies. Notwithstanding the limitations mentioned above, this study allows us to reach critical conclusions about economic, climate change, and energy policies.

Data Availability Statement:
The data presented in this study are available on reasonable request from the corresponding author.

Conflicts of Interest:
The authors declare no competing interests. Table A1. Some selected empirical studies on the electricity demand and temperature (degree days) nexus.  Due to climate change, residential electricity usage is more likely to increase in hot weather than in cold weather. Accounting for socioeconomic factors, the marginal effect of CDD on electricity consumption first increases with an increase in income.

Appendix A
However, when income increases further, the marginal increase curve turns flat. A warmer summer would have a more significant effect than a colder winter, meaning an increase in annual electricity usage due to global warming.