A Geographically Temporal Weighted Regression Approach with Travel Distance for House Price Estimation

Previous studies have demonstrated that non-Euclidean distance metrics can improve model fit in the geographically weighted regression (GWR) model. However, the GWR model often considers spatial nonstationarity and does not address variations in local temporal issues. Therefore, this paper explores a geographically temporal weighted regression (GTWR) approach that accounts for both spatial and temporal nonstationarity simultaneously to estimate house prices based on travel time distance metrics. Using house price data collected between 1980 and 2016, the house price response and explanatory variables are then modeled using both the GWR and the GTWR approaches. Comparing the GWR model with Euclidean and travel distance metrics, the GTWR model with travel distance obtains the highest value for the coefficient of determination (R2) and the lowest values for the Akaike information criterion (AIC). The results show that the GTWR model provides a relatively high goodness of fit and sufficient space-time explanatory power with non-Euclidean distance metrics. The results of this study can be used to formulate more effective policies for real estate management.


Introduction
The first law of geography, proposed by Waldo Tobler, is that "everything is related to everything else, but near things are more related than distant things" [1].Geographically weighted regression (GWR) is a method used in spatial statistical analysis tools to discover geographical variations in the relationship between a response variable and a set of covariates [2][3][4][5].For example, in Northern China, heating costs have a significant influence on house prices.However, the influence of heating costs on house prices is subtle in Southern China.Therefore, heating cost disparities could lead to differences in house prices in Northern and Southern China.The GWR model assumes that all explanatory variables vary over space, but the global effects are often neglected.The mixed geographically weighted regression (MGWR) model has been proposed to explore spatially stationary and non-stationary effects [6,7].MGWR empirical examples show that there is significant spatial variation in some of the estimated parameters, while the global effects provide evidence for policy-based linkages and an economically-connected housing market [6,7].Lu et al. investigated the GWR model by applying it while considering road network distance and travel time metrics [8,9].Daniel P. McMillen demonstrated that nonparametric estimation is feasible for large datasets, using statistical tests of individual covariates and tests of model specifications [10,11].
Entropy 2016, 18, 303 2 of 13 Without considering temporal variations, the first GTWR approach introduced considered spatial and temporal heterogeneity [12,13].The GTWR model is an efficient tool that provides information for understanding how spatial patterns change over time.Douglas H. Wrenn and Abdoul G. Sam used a series of Monte Carlo experiments with an extension of the geographically weighted likelihood regression (GWLR) model to demonstrate that temporal heterogeneity can improve the model's performance when heterogeneity exists in the spatial and temporal dimensions [14].Much attention has also been paid to research into spatial and temporal autocorrelation [15,16].A two-stage least squares estimation framework was proposed to address the nonstationarity and autocorrelated problems.The advantages of this model are that it does not require a prespecified distribution and it reduces the computational complexity [16].
In the real world, different distance metrics (e.g., travel distance or time under varying conditions) could be useful inputs for spatial analytical models [17,18].Considering travel distance or time, rather than Euclidean distance to the nearest service, are simple and commonly used spatial measures [19].Using the province of Nova Scotia as an example, Nadine Schuurman measured spatial access to primary health care physicians using a modified gravity model [20].The results allow the reader to visualize relative geographical access to primary health care.Nikolaos Yiannakoulias considered the effects on primary health care services in Edmonton, Alberta, Canada of both free-flow travel time and "congested with turn penalties" travel time using a model that employed a gravity-based measure of spatial accessibility.The results showed that using the "congested with turn penalties" travel time is more useful for measuring absolute travel time than simply modeling relative spatial accessibility [21].
Some recent works have analyzed and proposed some improvements and alternatives for the non-Euclidean distance metrics in geographically weighted regression.For instance, a Minkowski approach was demonstrated to approximate the underlying distance metric using the GWR model [22].Lu et al. proposed non-Euclidean distance metrics that used road network distance and travel time metrics to calibrate the GWR model.The results showed that non-Euclidean distance metrics are superior to Euclidean distance metrics for the GWR model.Our contribution also focuses on non-Euclidean distance (travel distance) but particularly in its application within the GTWR model, which was developed to account for local effects in both space and time.In addition, the non-Euclidean distance explanatory variables (distance to a primary school or shopping mall) are also introduced to calibrate the GTWR model.
The remainder of this article is organized as follows: in Section 2, we introduce the study area and experimental data; Section 3 provides some background information, a description of the GTWR model and the proposed algorithm flow; in Section 4, we describe our experimental results; and Section 5 summarizes our contributions and outlines future directions for related research.

Study Area and Experimental Data
As the process of open reform in China moves forward, it has led to typical real estate market-based patterns in the metropolitan area.The hedonic real estate model is used to identify the contribution of the characteristics of a house (or other residence) to its purchase price [23][24][25][26][27][28].Those characteristics can be divided into three general classes: structural attributes (house age, number of bedrooms, presence of a garage, etc.), locational attributes (these vary between properties and include good transportation links, accessibility to shops and services, proximity to downtown, etc.) and neighborhood attributes (population density, unemployment, measures of social stress, etc.).Some machine learning methods have been introduced to estimate house prices [29,30].
Houses are places for people to live or work; they constitute a main space for human activities.Clusters of houses connected by roads or paths form a community [9].Therefore, it is reasonable to consider the accessibility relationships underlying a real estate market.Geographical accessibility comprises both accessibility and proximity.The availability of points of interest (POIs) through geographic services, such as Baidu, has made it possible to calculate road-network distances between residential plots and POIs, which can be particularly important in cities where driving is the dominant Entropy 2016, 18, 303 3 of 13 transportation modality.Network distances may provide a small improvement over the use of straight line distance metrics, particularly within urban areas.Although these distance metrics are an improvement on yet simpler models of distance, they remain somewhat unrealistic because they do not account for traffic congestion, which can alter the duration of a trip.However, it is possible to generate more accurate network travel cost metrics using detailed data on transportation infrastructure by accounting for the role of posted speed limits, traffic congestion, and so on.
This paper describes a case study carried out using housing price data observed in the urban area of Beijing, China.An overview of the variables involved in housing prices is shown in Table 1.A total of 1961 residential houses are included in the study; their geolocations are shown in Figure 1.The study data were provided by the National Bureau of Statistics.We extracted structural, neighborhood, and temporal variables to explain the variations in house prices.The dependent variable is the logarithmically-transformed sales price (lnp) of the house.Unit prices are calculated in RMB.The structural characteristics of each house are described by four covariates.The plot ratio, also called floor area ratio, is the ratio of a building's total floor area (gross floor area) to the size of the piece of land upon which it is built [31].For example, in case of a land area of 100 m 2 and a floor area ratio of 300%, a building with maximum floor area of 300 m 2 can be constructed.The plot ratio is logarithmically transformed as LnPlotRatio.The green ratio is the ratio of green space to the entire plot area.The green ratio is logarithmically transformed as LnGreenRatio.The floor area of the house (in m 2 ) is logarithmically transformed as LnFloorArea.The management fee of the property (in RMB/m 2 ) is logarithmically transformed as LnPropertyFee.The temporal variable is the age of the building at the time of its last sale (in year).We calculate the Euclidean distance from each residential plot to the nearest primary school and shopping mall (LnEucD PriSchool , LnEucD ShoppingMall ), as well as the travel distance from each residential plot to the nearest primary school and shopping mall (LnTD PriSchool , LnTD ShoppingMall ).
Multicollinearity is investigated using the diagnostic tools of the variance inflation factor (VIF), condition index and variance-decomposition proportions [32].VIF is defined as measuring the multicollinearity of a variable with the other independent variables in the analysis, and it is connected directly to the variance of the regression coefficient associated with this independent variable.The VIF value quantifies how much the variance is inflated by the existence of correlation among the explanatory variables in the model-in other words, VIF values are indicators for the severity of multicollinearity.A VIF value of 1 means that there is no correlation among the explanatory predictor and the remaining variables, while a VIF value greater than 10 means that that explanatory variable should be eliminated.Belsley suggests using condition indexes greater than or equal to 30 and variance proportions greater than 0.50 for each variance component as an indication of collinearity in a regression model [33,34].In this study, the VIF values of the explanatory covariates are less than 10, and the condition indexes of all explanatory covariates and the intercept are less than 30.

Geographically Temporal Weighted Regression Model
The GWR approach is a spatially varying coefficient regression model [35][36][37].Huang et al. developed a GTWR model to address spatial and temporal non-stationarity issues simultaneously by incorporating temporal effects into the GWR model [9].To effectively delineate the spatio-temporal quantitative relationship between dependent and independent variables, a GTWR model with Euclidean and travel distance was developed to improve the estimation accuracy.
The GTWR model can be expressed as: where (u i , v i , t i ) epresents the given coordinate of a point i in a space (u i , v i ) at time t i ; β 0 (u i , v i , t i ) represents the intercept value; and β k (u i , v i , t i ) represents a set of values for the number p of parameters at point i.The random error conforming to a normal distribution is denoted by There is no correlation in random error between different points: Cov ε i , ε j = 0 (i = j).
The regression parameter βi at point i can be calculated using the least squares model, as follows: Entropy 2016, 18, 303 The fitted value ŷ is: where the weighting matrix W (u i , v i , t i ) is based on the distances between the regression point i and the data points around it.An adaptive kernel function is adopted and an optimum spatial kernel bandwidth is achieved for this study area.The Gaussian function is the most commonly used weighting function: where h is a nonnegative parameter known as bandwidth that produces a decay of influence relative to the distance between the locations i and j.The spatial, temporal, and spatio-temporal distances between location i and j are as follows: Here, ϕ S is the scale factor of spatial distance, while ϕ T stands for the scale factor of temporal distance: where h ST , h T , and h S are the parameters of the spatio-temporal, spatial, and temporal bandwidths, respectively, and h 2 S = h 2 ST /ϕ S and h 2 T = h 2 ST /ϕ T .The optimal spatial bandwidth h S is achieved by the optimization technique using the GWR model.
According to Equation (2), there is no influence on the estimation of coefficients when the kernel function is multiplied by a constant.The kernel function is determined by the distance and bandwidth.Therefore, the spatio-temporal distance D ST ij could be written as follows: where τ = ϕ T ϕ S .The purpose of the spatio-temporal parameter τ is to enlarge/reduce the temporal effect to match the spatial distance.To reduce the number of parameters and the computational complexity, set ϕ S = 1; then, there is only one unknown parameter, τ.The spatio-temporal weight function can be constructed as follows: If the predicted value of y i from GTWR is denoted by ŷi (τ), the sum of the squared error can be written as follows: The spatio-temporal parameter τ is achieved automatically with an optimization technique by minimizing Equation ( 9) in terms of goodness-of-fit statistics.
The AIC contains a penalty for the complexity of the model and provides a measure of the information distance between the fitted model and the unknown "true" model.As a general rule, improvements in the AIC less than 3 in value could easily arise as a result of sampling error, whereas values greater than 3 are more likely to be due to a genuine difference in models [3,8].The AIC is expressed as: where n is the sample size; σ is the estimated standard deviation of the error term; and tr(S) denotes the trace of the hat matrix S. The hat matrix S is the projection matrix from the observed y to the fitted ŷ where each row s i of the hat matrix is: where X i is its i-th row of the matrix of explanatory variables X.

Measuring Travel Distance on a Beijing Road Network
To calibrate the GWR and GTWR models, the travel distance is used in both parts.As described by Lu and Curriero [8,9,38], the methods utilize non-Euclidean distances between residential plots.However, these methods do not consider the distance explanatory variables (i.e., the distance to the primary school or shopping mall).In this paper, the distances between residential plots are calculated using the travel distance.We also use travel distance instead of Euclidean distance as the distance metric to the nearest primary school and shopping mall.Travel distance is acquired from the Baidu Map API (the Route API), which, given starting and destination points, provides travel distance as a web service using the HTTP protocol.Two travel distance matrices are constructed and stored in a MySQL database (https://www.mysql.com).First, there are a total of 1961 residential plots; therefore, a two-dimensional 1961 × 1961 matrix for travel distances between residential plots was constructed and stored in the MySQL database.Second, there are 971 primary schools and 3983 shopping malls in the study area; therefore, a two-dimensional 1961 × 2 matrix for travel distances between residential plots to the nearest primary schools and shopping malls was constructed and stored to prepare for their invocation in the method.

The Proposed Algorithm Flow
The flow of the proposed approach is shown in Figure 2. The steps of the proposed algorithm are as follows: (1) Construct Euclidean distance matrices: Construct the residential plot to residential plot, residential plot to primary school, and residential plot to shopping mall Euclidean distance matrices.
(2) Construct travel distance matrices: Construct the residential plot to residential plot, residential plot to primary school, and residential plot and shopping mall travel distance matrices.
(3) Find the optimal spatio-temporal parameter, τ, which is used to harmonize the different spatial and temporal units.Equation ( 9) implements a validation process to achieve the optimal spatio-temporal parameter τ in terms of goodness-of-fit.
(4) Calculate the response variable fitted value: Compute the fitted value ŷ according to Equation (3).
(5) Accuracy assessment: The R 2 and AIC statistics are selected to assess the accuracy of the proposed approach.
a two-dimensional 1961 × 1961 matrix for travel distances between residential plots was constructed and stored in the MySQL database.Second, there are 971 primary schools and 3983 shopping malls in the study area; therefore, a two-dimensional 1961 × 2 matrix for travel distances between residential plots to the nearest primary schools and shopping malls was constructed and stored to prepare for their invocation in the method.

The Proposed Algorithm Flow
The flow of the proposed approach is shown in Figure 2. The steps of the proposed algorithm are as follows:

Experimental Results and Comparisons
In this section, the spatial and temporal heterogeneities were first tested using statistical hypotheses.Then, we performed regressions using both the traditional GWR and the proposed GTWR model, respectively, for the housing data.For comparison purposes, two different GWR-based approaches, GWR and GTWR with Euclidean and travel distance, were also implemented.All methods were tested against the same dataset, and we evaluated their goodness of fit in terms of the R 2 and AIC criteria.

Spatial and Temporal Heterogeneity Test of Significance
The statistical value proposed by Leung has been constructed to explain the spatial variation of the estimated values of parameters β i (i = 1, 2, ..., n) [39].A test can be carried out by comparing the p-values against a threshold significance level, for example, 0.05.When a p-value is less than 0.05, the null hypothesis is rejected; otherwise, it is accepted.Table 2 lists the F-statistic value of each variable and its corresponding p-value in the GWR models, and Table 3 lists the F-statistic value of each variable and its corresponding p-value in the GTWR models.The statistically significant values at the 5% level are marked with an asterisk (*).As Table 2 shows, the parameters Intercept, LnPlotRatio, LnGreenRatio, LnFloorArea, LnEucD PriSchool , and age have significant spatial variation in the GWR model using Euclidean distance.The variable LnPropertyFee does not have spatial variation in the GWR with either the Euclidean or travel distance model or in the GTWR with the Euclidean model, but LnPropertyFee does show significant spatial variation in the GTWR with the travel distance model.

Comparison of the GTWR and GWR Models with Euclidean and Travel Distance Metrics
Summaries of the GWR coefficients estimation with Euclidean and travel distance, including the minimum (Min), lower quartile (LQ), median (Med), upper quartile (UQ), and maximum (Max) are presented in Tables 4 and 5. Summaries of the GTWR coefficients estimation with Euclidean and travel distance are reported in Tables 6 and 7. When using the GWR and GTWR models with Euclidean and travel distance, LnEucD PriSchool is negatively correlated with house prices, as shown in Table 4.In other words, as the distance to the nearest primary school increases, the house price decreases.In contrast, LnFloorArea is positively correlated with house prices: the larger the living area is, the higher the house price is.However, there is no significant correlation between the variable LnEucD ShoppingMall and house prices since the coefficients of LnEucD ShoppingMall have both positive and negative values; therefore, shopping malls are not a major factor influencing house prices; however, this result occurred in this study because shopping malls are both common and relatively uniformly distributed in Beijing in the study area.
The F-test was implemented to compare with the improved sum of squares accounted for by the GWR and GTWR with Euclidean and travel distance metrics.These comparisons can be expressed in the form of an analysis of variance (ANOVA) table to compare the residual mean squares for these models, as reported in Table 8.In this table, the second column lists the residual sum of squares (RSS) of the models and the improvement of one model compared to another.The third column lists the degrees of freedom (DF) for each model, and the fourth shows the mean squared error (MS).The fifth and sixth columns show the F statistic and its corresponding significance level.The R 2 and AIC measurements are also listed in Table 8.As Table 8 shows, when using the GWR model with travel distance (TD) and ED (Euclidean distance), RSS improves by 13.4,MS improves by 1.46, R 2 improves by 0.013, and AIC improves by 91.122.In contrast, when using the GTWR and the GWR model with TD, RSS improves by 46.3, MS improves by 2.04, R 2 improves by 0.046, and AIC is reduced by 382.422.According to Fotheringham [40], a "serious" difference between the two models is generally regarded as one in which the difference in AIC values between the models is greater than three.The GTWR model with TD achieved both the maximum R 2 value and the minimum RSS, AIC value and, consequently, obtained the best performance.The models' performances and their spatio-temporal nonstationarity were explored visually by mapping the local coefficient estimates of the variable LnEucD PriSchool .The maps in Figure 3 show the distribution of each individual coefficient.The models' performances and their spatio-temporal nonstationarity were explored visually by mapping the local coefficient estimates of the variable LnEucD .The maps in Figure 3 show the distribution of each individual coefficient.
As the maps in Figure 3 show, house prices are more strongly influenced in the metropolitan areas within the outer ring road of Beijing than in the suburban areas.Compared with primary schools in the suburban areas, primary schools in the metropolitan areas have excellent faculties and educational facilities.Therefore, house prices are influenced much more significantly by primary school proximity in the metropolitan areas than in the suburban areas.This result shows that it is critical for planning departments to arrange the locations of primary schools carefully to boost the sustainable development of the real estate industry.Some exceptions can be found.For example, in the northwest portion of the suburban areas; the variable LnEucD shows a significant negative correlation.This occurs because the area is home to a beautiful tourist spot named the Summer Palace, whose beauty and proximity influences nearby house prices.

Conclusions
This study analyzed data reflecting the spatial and temporal heterogeneity of house prices.The GWR and GTWR models used in the study were built based on house price data from 1980 to 2016.The performances of these two types of models were then compared based on and AIC.This article demonstrates that the GTWR model, which considers travel distance, is a more efficient approach for testing spatial and temporal nonstationarity in Beijing.
First, the GTWR model performs better than the GWR model with Euclidean and travel distance As the maps in Figure 3 show, house prices are more strongly influenced in the metropolitan areas within the outer ring road of Beijing than in the suburban areas.Compared with primary schools in the suburban areas, primary schools in the metropolitan areas have excellent faculties and educational facilities.Therefore, house prices are influenced much more significantly by primary school proximity in the metropolitan areas than in the suburban areas.This result shows that it is critical for planning departments to arrange the locations of primary schools carefully to boost the sustainable development of the real estate industry.Some exceptions can be found.For example, in the northwest portion of the suburban areas; the variable LnEucD PriSchool shows a significant negative correlation.This occurs because the area is home to a beautiful tourist spot named the Summer Palace, whose beauty and proximity influences nearby house prices.

Conclusions
This study analyzed data reflecting the spatial and temporal heterogeneity of house prices.The GWR and GTWR models used in the study were built based on house price data from 1980 to 2016.The performances of these two types of models were then compared based on R 2 and AIC.This article demonstrates that the GTWR model, which considers travel distance, is a more efficient approach for testing spatial and temporal nonstationarity in Beijing.
First, the GTWR model performs better than the GWR model with Euclidean and travel distance metrics.After spatial and temporal nonstationarity tests, the GTWR model can account for the spatial and temporal variations that exist in the house prices.Second, the GTWR performs better when using travel distance than when using Euclidean distance.This is because, in real life, people assess distances between their residential plots, primary schools, and shopping malls not by planar distance, but by distance when traveling along the road network.Third, the GTWR model revealed that distance to the nearest primary school plays an important negatively-correlated role in determining house prices in Beijing.
Although the present study demonstrates the utility of GTWR models with Euclidean and travel distance metrics for understanding specific location and temporal relationships between house prices and explanatory variables, some critical questions remain to be answered.This paper considered only spatial and temporal heterogeneity, but in the real world, some explanatory variables vary with spatial locations, whereas others do not.In future studies, we will focus on an MGTWR model to estimate house prices.Furthermore, this paper considers only the spatio-temporal heterogeneity and ignores spatial autocorrelation issues.More attention should be paid to the geographically-and temporally-weighted autoregressive model.

Figure 1 .
Figure 1.Map of the study area.Figure 1. Map of the study area.

Figure 1 .
Figure 1.Map of the study area.Figure 1. Map of the study area.

Figure 2 .
Figure 2. The flow of the proposed approach.Figure 2. The flow of the proposed approach.

Figure 2 .
Figure 2. The flow of the proposed approach.Figure 2. The flow of the proposed approach.

Figure 3 .
Figure 3. Distance to primary school coefficients map over the study region: (a) GWR model with Euclidean distance; (b) GWR model with travel distance; (c) GTWR model with Euclidean distance; and (d) GTWR model with travel distance.

Figure 3 .
Figure 3. Distance to primary school coefficients map over the study region: (a) GWR model with Euclidean distance; (b) GWR model with travel distance; (c) GTWR model with Euclidean distance; and (d) GTWR model with travel distance.

Table 1 .
Variables used to predict housing prices in Beijing, China.

Table 2 .
Nonstationarity of parameters in the GWR models.
* The statistically significant values at the 5% level.

Table 3 .
Nonstationarity of parameters in the GTWR models.
* The statistically significant values at the 5% level.

Table 4 .
GWR coefficients estimate summaries with Euclidean distance.

Table 5 .
GWR coefficients estimate summaries with travel distance.

Table 7 .
GTWR coefficients estimate summaries with travel distance.

Table 8 .
ANOVA comparison between GWR and GTWR with Euclidean and travel distance.