In-class_Ex3

Author

J X LOW

Overview

Getting Started

The code chunk below load the following packages:

  • tmap: for thematic mapping
  • sf for geospatial data handling
  • sp for efficiency of computation of spatial data frame
  • reshape2 for pivoting long/fat and to handle matrix
  • tidyverse for non-spatial data handling.
  • knitr for creating html table
pacman::p_load(tmap, sf, sp, DT,
               performance, reshape2,
               ggpubr, tidyverse)

Computing Distance Matrix

In spatial interaction, a distance matrix is a table that shows the distance between pairs of locations. For example, in the table below we can see an Euclidean distance of 3926.0025 between MESZ01 and RVSZ05, of 3939.1079 between MESZ01 and SRSZ01, and so on. By definition, an location’s distance from itself, which is shown in the main diagonal of the table, is 0.

Import mpsz for distance matrix, which is a sf tibble dataframe object class as follows.

mpsz <- st_read(dsn = "data/geospatial",
                   layer = "MPSZ-2019") %>%
  st_transform(crs = 3414)
Reading layer `MPSZ-2019' from data source 
  `C:\jayexx\ISSS624\In-class_Exercises\In-class_Ex3\data\geospatial' 
  using driver `ESRI Shapefile'
Simple feature collection with 332 features and 6 fields
Geometry type: MULTIPOLYGON
Dimension:     XY
Bounding box:  xmin: 103.6057 ymin: 1.158699 xmax: 104.0885 ymax: 1.470775
Geodetic CRS:  WGS 84

Converting from sf data.table to SpatialPolygonsDataFrame

At least two ways to compute the required distance matrix. 1. Based on sf 2. Based on sp. From past experience, computing distance matrix by using sf function takes relatively longer than sp method especially if data set is large. In view of this, sp method is used as follows.

mpsz_sp <- as(mpsz, "Spatial")
mpsz_sp
class       : SpatialPolygonsDataFrame 
features    : 332 
extent      : 2667.538, 56396.44, 15748.72, 50256.33  (xmin, xmax, ymin, ymax)
crs         : +proj=tmerc +lat_0=1.36666666666667 +lon_0=103.833333333333 +k=1 +x_0=28001.642 +y_0=38744.572 +ellps=WGS84 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs 
variables   : 6
names       : SUBZONE_N, SUBZONE_C, PLN_AREA_N, PLN_AREA_C,       REGION_N, REGION_C 
min values  : ADMIRALTY,    AMSZ01, ANG MO KIO,         AM, CENTRAL REGION,       CR 
max values  :    YUNNAN,    YSSZ09,     YISHUN,         YS,    WEST REGION,       WR 

Computing the distance matrix

Use spDists() of sp package to compute the Euclidean distance between the centroids of the planning subzones as follows.

dist <- spDists(mpsz_sp, 
                longlat = FALSE)
head(dist, n=c(10, 10))
           [,1]       [,2]      [,3]      [,4]       [,5]      [,6]      [,7]
 [1,]     0.000  3926.0025  3939.108 20252.964  2989.9839  1431.330 19211.836
 [2,]  3926.003     0.0000   305.737 16513.865   951.8314  5254.066 16242.523
 [3,]  3939.108   305.7370     0.000 16412.062  1045.9088  5299.849 16026.146
 [4,] 20252.964 16513.8648 16412.062     0.000 17450.3044 21665.795  7229.017
 [5,]  2989.984   951.8314  1045.909 17450.304     0.0000  4303.232 17020.916
 [6,]  1431.330  5254.0664  5299.849 21665.795  4303.2323     0.000 20617.082
 [7,] 19211.836 16242.5230 16026.146  7229.017 17020.9161 20617.082     0.000
 [8,] 14960.942 12749.4101 12477.871 11284.279 13336.0421 16281.453  5606.082
 [9,]  7515.256  7934.8082  7649.776 18427.503  7801.6163  8403.896 14810.930
[10,]  6391.342  4975.0021  4669.295 15469.566  5226.8731  7707.091 13111.391
           [,8]      [,9]     [,10]
 [1,] 14960.942  7515.256  6391.342
 [2,] 12749.410  7934.808  4975.002
 [3,] 12477.871  7649.776  4669.295
 [4,] 11284.279 18427.503 15469.566
 [5,] 13336.042  7801.616  5226.873
 [6,] 16281.453  8403.896  7707.091
 [7,]  5606.082 14810.930 13111.391
 [8,]     0.000  9472.024  8575.490
 [9,]  9472.024     0.000  3780.800
[10,]  8575.490  3780.800     0.000
Q&A

Do you know why the distance is calculated between two centroids of a pair of spatial polygons?

Labelling column and row heanders of a distance matrix

create a list sorted according to the the distance matrix by planning sub-zone code

sz_names <- mpsz$SUBZONE_C

attach SUBZONE_C to row and column for distance matrix matching ahead

colnames(dist) <- paste0(sz_names)
rownames(dist) <- paste0(sz_names)

Pivoting distance value by SUBZONE_C

Pivot the distance matrix into a long table by using the row and column subzone codes as show in the code chunk below.

distPair <- melt(dist) %>%
  rename(dist = value)
head(distPair, 10)
     Var1   Var2      dist
1  MESZ01 MESZ01     0.000
2  RVSZ05 MESZ01  3926.003
3  SRSZ01 MESZ01  3939.108
4  WISZ01 MESZ01 20252.964
5  MUSZ02 MESZ01  2989.984
6  MPSZ05 MESZ01  1431.330
7  WISZ03 MESZ01 19211.836
8  WISZ02 MESZ01 14960.942
9  SISZ02 MESZ01  7515.256
10 SISZ01 MESZ01  6391.342

Notice that the same-zone distance is 0

Updating intra-zonal distances

Append a constant value to replace the intra-zonal distance of 0.

First, we will select and find out the minimum value of the distance by using summary().

distPair %>%
  filter(dist > 0) %>%
  summary()
      Var1             Var2             dist        
 MESZ01 :   331   MESZ01 :   331   Min.   :  173.8  
 RVSZ05 :   331   RVSZ05 :   331   1st Qu.: 7149.5  
 SRSZ01 :   331   SRSZ01 :   331   Median :11890.0  
 WISZ01 :   331   WISZ01 :   331   Mean   :12229.4  
 MUSZ02 :   331   MUSZ02 :   331   3rd Qu.:16401.7  
 MPSZ05 :   331   MPSZ05 :   331   Max.   :49894.4  
 (Other):107906   (Other):107906                    

constant distance value of 50m is added into intra-zones distance

distPair$dist <- ifelse(distPair$dist == 0,
                        50, distPair$dist)

check the result data.frame.

distPair %>%
  summary()
      Var1             Var2             dist      
 MESZ01 :   332   MESZ01 :   332   Min.   :   50  
 RVSZ05 :   332   RVSZ05 :   332   1st Qu.: 7097  
 SRSZ01 :   332   SRSZ01 :   332   Median :11864  
 WISZ01 :   332   WISZ01 :   332   Mean   :12193  
 MUSZ02 :   332   MUSZ02 :   332   3rd Qu.:16388  
 MPSZ05 :   332   MPSZ05 :   332   Max.   :49894  
 (Other):108232   (Other):108232                  

rename the origin and destination fields

distPair <- distPair %>%
  rename(orig = Var1,
         dest = Var2)

save the dataframe for future use

write_rds(distPair, "data/rds/distPair.rds") 

Flow Data

import od_data

od_data <- read_rds("data/rds/od_data.rds")

compute the total passenger trip between and within planning subzones by using the code chunk below. The output is all flow_data

flow_data <- od_data %>%
  group_by(ORIGIN_SZ, DESTIN_SZ) %>% 
  summarize(TRIPS = sum(MORNING_PEAK)) 
`summarise()` has grouped output by 'ORIGIN_SZ'. You can override using the
`.groups` argument.

display flow_data dataframe

head(flow_data, 10)
# A tibble: 10 × 3
# Groups:   ORIGIN_SZ [1]
   ORIGIN_SZ DESTIN_SZ TRIPS
   <chr>     <chr>     <dbl>
 1 AMSZ01    AMSZ01     2694
 2 AMSZ01    AMSZ02    10591
 3 AMSZ01    AMSZ03    14980
 4 AMSZ01    AMSZ04     3106
 5 AMSZ01    AMSZ05     7734
 6 AMSZ01    AMSZ06     2306
 7 AMSZ01    AMSZ07     1824
 8 AMSZ01    AMSZ08     2734
 9 AMSZ01    AMSZ09     2300
10 AMSZ01    AMSZ10      164

Separating intra-flow from passenger volume df

Code chunk below is used to add three new fields in flow_data dataframe

flow_data$FlowNoIntra <- ifelse(
  flow_data$ORIGIN_SZ == flow_data$DESTIN_SZ, 
  0, flow_data$TRIPS)
flow_data$offset <- ifelse(
  flow_data$ORIGIN_SZ == flow_data$DESTIN_SZ, 
  0.000001, 1)

Combining passenger volume data with distance value

Before we can join flow_data and distPair, we need to convert data value type of ORIGIN_SZ and DESTIN_SZ fields of flow_data dataframe into factor data type.

flow_data$ORIGIN_SZ <- as.factor(flow_data$ORIGIN_SZ)
flow_data$DESTIN_SZ <- as.factor(flow_data$DESTIN_SZ)

left_join() of dplyr will be used to flow_data dataframe and distPair dataframe. The output is called flow_data1.

flow_data1 <- flow_data %>%
  left_join (distPair,
             by = c("ORIGIN_SZ" = "orig",
                    "DESTIN_SZ" = "dest"))

Preparing OD data

Importing population data

pop <- read_csv("data/aspatial/pop.csv", show_col_types = FALSE)

Geospatial data wrangling

pop <- pop %>%
  left_join(mpsz,
            by = c("PA" = "PLN_AREA_N",
                   "SZ" = "SUBZONE_N")) %>%
  select(1:6) %>%
  rename(SZ_NAME = SZ,
         SZ = SUBZONE_C)

Preparing origin attribute

flow_data1 <- flow_data1 %>%
  left_join(pop,
            by = c(ORIGIN_SZ = "SZ")) %>%
  rename(ORIGIN_AGE7_12 = AGE7_12,
         ORIGIN_AGE13_24 = AGE13_24,
         ORIGIN_AGE25_64 = AGE25_64) %>%
  select(-c(PA, SZ_NAME))

Preparing destination attribute

flow_data1 <- flow_data1 %>%
  left_join(pop,
            by = c(DESTIN_SZ = "SZ")) %>%
  rename(DESTIN_AGE7_12 = AGE7_12,
         DESTIN_AGE13_24 = AGE13_24,
         DESTIN_AGE25_64 = AGE25_64) %>%
  select(-c(PA, SZ_NAME))

Label the output data file SIM_data. it is in rds data file format.

write_rds(flow_data1, "data/rds/SIM_data")

Calibrating Spatial Interaction Models

In this section, you will learn how to calibrate Spatial Interaction Models by using Poisson Regression method.

Importing the modelling data

Firstly, let us import the modelling data by using the code chunk below.

SIM_data <- read_rds("data/rds/SIM_data.rds")

Visualising the dependent variable

Firstly, let us plot the distribution of the dependent variable (i.e. TRIPS) by using histogram method by using the code chunk below.

ggplot(data = SIM_data,
       aes(x = TRIPS)) +
  geom_histogram()
`stat_bin()` using `bins = 30`. Pick better value with `binwidth`.

Notice that the distribution is highly skewed and not resemble bell shape or also known as normal distribution.

Next, let us visualise the relation between the dependent variable and one of the key independent variable in Spatial Interaction Model, namely distance.

ggplot(data = SIM_data,
       aes(x = dist,
           y = TRIPS)) +
  geom_point() +
  geom_smooth(method = lm)
`geom_smooth()` using formula = 'y ~ x'

Notice that their relationship hardly resemble linear relationship.

On the other hand, if we plot the scatter plot by using the log transformed version of both variables, we can see that their relationship is more resemble linear relationship.

ggplot(data = SIM_data,
       aes(x = log(dist),
           y = log(TRIPS))) +
  geom_point() +
  geom_smooth(method = lm)
`geom_smooth()` using formula = 'y ~ x'

Checking for variables with zero values

Since Poisson Regression is based of log and log 0 is undefined, it is important for us to ensure that no 0 values in the explanatory variables.

In the code chunk below, summary() of Base R is used to compute the summary statistics of all variables in SIM_data data frame.

summary(SIM_data)
  ORIGIN_SZ          DESTIN_SZ             TRIPS           FlowNoIntra      
 Length:14274       Length:14274       Min.   :     1.0   Min.   :     1.0  
 Class :character   Class :character   1st Qu.:    11.0   1st Qu.:    11.0  
 Mode  :character   Mode  :character   Median :    56.0   Median :    56.0  
                                       Mean   :   664.3   Mean   :   664.3  
                                       3rd Qu.:   296.0   3rd Qu.:   296.0  
                                       Max.   :104167.0   Max.   :104167.0  
     offset       dist         ORIGIN_AGE7_12 ORIGIN_AGE13_24 ORIGIN_AGE25_64
 Min.   :1   Min.   :  173.8   Min.   :   0   Min.   :    0   Min.   :    0  
 1st Qu.:1   1st Qu.: 3465.4   1st Qu.: 240   1st Qu.:  460   1st Qu.: 2210  
 Median :1   Median : 6121.0   Median : 710   Median : 1400   Median : 7030  
 Mean   :1   Mean   : 6951.8   Mean   :1037   Mean   : 2278   Mean   :10536  
 3rd Qu.:1   3rd Qu.: 9725.1   3rd Qu.:1500   3rd Qu.: 3282   3rd Qu.:15830  
 Max.   :1   Max.   :26135.8   Max.   :6340   Max.   :16380   Max.   :74610  
 DESTIN_AGE7_12 DESTIN_AGE13_24 DESTIN_AGE25_64
 Min.   :   0   Min.   :    0   Min.   :    0  
 1st Qu.: 250   1st Qu.:  460   1st Qu.: 2210  
 Median : 720   Median : 1430   Median : 7120  
 Mean   :1040   Mean   : 2305   Mean   :10648  
 3rd Qu.:1500   3rd Qu.: 3290   3rd Qu.:15830  
 Max.   :6340   Max.   :16380   Max.   :74610  

Checking for variables with zero values

Since Poisson Regression is based of log and log 0 is undefined, it is important for us to ensure that no 0 values in the explanatory variables.

In the code chunk below, summary() of Base R is used to compute the summary statistics of all variables in SIM_data data frame.

summary(SIM_data)
  ORIGIN_SZ          DESTIN_SZ             TRIPS           FlowNoIntra      
 Length:14274       Length:14274       Min.   :     1.0   Min.   :     1.0  
 Class :character   Class :character   1st Qu.:    11.0   1st Qu.:    11.0  
 Mode  :character   Mode  :character   Median :    56.0   Median :    56.0  
                                       Mean   :   664.3   Mean   :   664.3  
                                       3rd Qu.:   296.0   3rd Qu.:   296.0  
                                       Max.   :104167.0   Max.   :104167.0  
     offset       dist         ORIGIN_AGE7_12 ORIGIN_AGE13_24 ORIGIN_AGE25_64
 Min.   :1   Min.   :  173.8   Min.   :   0   Min.   :    0   Min.   :    0  
 1st Qu.:1   1st Qu.: 3465.4   1st Qu.: 240   1st Qu.:  460   1st Qu.: 2210  
 Median :1   Median : 6121.0   Median : 710   Median : 1400   Median : 7030  
 Mean   :1   Mean   : 6951.8   Mean   :1037   Mean   : 2278   Mean   :10536  
 3rd Qu.:1   3rd Qu.: 9725.1   3rd Qu.:1500   3rd Qu.: 3282   3rd Qu.:15830  
 Max.   :1   Max.   :26135.8   Max.   :6340   Max.   :16380   Max.   :74610  
 DESTIN_AGE7_12 DESTIN_AGE13_24 DESTIN_AGE25_64
 Min.   :   0   Min.   :    0   Min.   :    0  
 1st Qu.: 250   1st Qu.:  460   1st Qu.: 2210  
 Median : 720   Median : 1430   Median : 7120  
 Mean   :1040   Mean   : 2305   Mean   :10648  
 3rd Qu.:1500   3rd Qu.: 3290   3rd Qu.:15830  
 Max.   :6340   Max.   :16380   Max.   :74610  

Unconstrained Spatial Interaction Model

In this section, you will learn how to calibrate an unconstrained spatial interaction model by using glm() of Base Stats. The explanatory variables are origin population by different age cohort, destination population by different age cohort (i.e. ORIGIN_AGE25_64) and distance between origin and destination in km (i.e. dist).

The general formula of Unconstrained Spatial Interaction Model:

lambda_ij = exp(k + mu ln V_i + alpha ln W_j - Beta ln d_ij)

The code chunk used to calibrate to model is shown below:

SIM_data$ORIGIN_AGE25_64 <- ifelse(SIM_data$ORIGIN_AGE25_64 == 0,
                        0.0000001, SIM_data$ORIGIN_AGE25_64)
SIM_data$DESTIN_AGE25_64 <- ifelse(SIM_data$DESTIN_AGE25_64 == 0,
                        0.0000001, SIM_data$DESTIN_AGE25_64)


uncSIM <- glm(formula = TRIPS ~ 
                log(ORIGIN_AGE25_64) + 
                log(DESTIN_AGE25_64) +
                log(dist),
              family = poisson(link = "log"),
              data = SIM_data,
              na.action = na.exclude)
uncSIM

Call:  glm(formula = TRIPS ~ log(ORIGIN_AGE25_64) + log(DESTIN_AGE25_64) + 
    log(dist), family = poisson(link = "log"), data = SIM_data, 
    na.action = na.exclude)

Coefficients:
         (Intercept)  log(ORIGIN_AGE25_64)  log(DESTIN_AGE25_64)  
           18.375357              0.048510             -0.003123  
           log(dist)  
           -1.495664  

Degrees of Freedom: 14273 Total (i.e. Null);  14270 Residual
Null Deviance:      36120000 
Residual Deviance: 21150000     AIC: 21230000

R-squared function

In order to measure how much variation of the trips can be accounted by the model we will write a function to calculate R-Squared value as shown below.

CalcRSquared <- function(observed,estimated){
  r <- cor(observed,estimated)
  R2 <- r^2
  R2
}

Next, we will compute the R-squared of the unconstrained SIM by using the code chunk below.

CalcRSquared(uncSIM$data$TRIPS, uncSIM$fitted.values)
[1] 0.1249537
r2_mcfadden(uncSIM)
# R2 for Generalized Linear Regression
       R2: 0.414
  adj. R2: 0.414

Origin (Production) constrained SIM

In this section, we will fit an origin constrained SIM by using the code3 chunk below.

The general formula of Origin Constrained Spatial Interaction Model

lambda_ij = exp(k + mu + alpha ln W_j - Beta ln d_ij)

orcSIM <- glm(formula = TRIPS ~ 
                 ORIGIN_SZ +
                 log(DESTIN_AGE25_64) +
                 log(dist),
              family = poisson(link = "log"),
              data = SIM_data,
              na.action = na.exclude)
summary(orcSIM)

Call:
glm(formula = TRIPS ~ ORIGIN_SZ + log(DESTIN_AGE25_64) + log(dist), 
    family = poisson(link = "log"), data = SIM_data, na.action = na.exclude)

Coefficients:
                       Estimate Std. Error   z value Pr(>|z|)    
(Intercept)           2.014e+01  5.326e-03  3781.553  < 2e-16 ***
ORIGIN_SZAMSZ02       6.756e-01  5.269e-03   128.237  < 2e-16 ***
ORIGIN_SZAMSZ03       3.609e-01  5.488e-03    65.762  < 2e-16 ***
ORIGIN_SZAMSZ04      -1.114e-01  6.003e-03   -18.563  < 2e-16 ***
ORIGIN_SZAMSZ05      -3.168e-01  6.800e-03   -46.583  < 2e-16 ***
ORIGIN_SZAMSZ06       5.709e-02  6.026e-03     9.474  < 2e-16 ***
ORIGIN_SZAMSZ07      -1.135e+00  1.103e-02  -102.892  < 2e-16 ***
ORIGIN_SZAMSZ08      -6.438e-01  1.029e-02   -62.537  < 2e-16 ***
ORIGIN_SZAMSZ09       9.370e-02  6.345e-03    14.769  < 2e-16 ***
ORIGIN_SZAMSZ10       4.968e-01  5.389e-03    92.188  < 2e-16 ***
ORIGIN_SZAMSZ11      -1.331e+00  1.449e-02   -91.881  < 2e-16 ***
ORIGIN_SZAMSZ12      -1.514e+00  1.275e-02  -118.789  < 2e-16 ***
ORIGIN_SZBDSZ01       1.368e+00  5.143e-03   266.065  < 2e-16 ***
ORIGIN_SZBDSZ02       9.655e-01  5.966e-03   161.847  < 2e-16 ***
ORIGIN_SZBDSZ03       1.159e+00  5.428e-03   213.611  < 2e-16 ***
ORIGIN_SZBDSZ04       2.017e+00  4.635e-03   435.159  < 2e-16 ***
ORIGIN_SZBDSZ05       1.068e+00  5.398e-03   197.895  < 2e-16 ***
ORIGIN_SZBDSZ06       1.277e+00  5.477e-03   233.109  < 2e-16 ***
ORIGIN_SZBDSZ07      -4.996e-01  1.116e-02   -44.788  < 2e-16 ***
ORIGIN_SZBDSZ08      -3.418e-01  1.029e-02   -33.199  < 2e-16 ***
ORIGIN_SZBKSZ01      -3.552e-01  7.547e-03   -47.067  < 2e-16 ***
ORIGIN_SZBKSZ02       1.334e-01  6.139e-03    21.732  < 2e-16 ***
ORIGIN_SZBKSZ03       4.097e-01  5.898e-03    69.461  < 2e-16 ***
ORIGIN_SZBKSZ04      -3.377e-01  7.076e-03   -47.721  < 2e-16 ***
ORIGIN_SZBKSZ05      -3.028e-01  7.407e-03   -40.875  < 2e-16 ***
ORIGIN_SZBKSZ06      -2.627e-01  6.874e-03   -38.213  < 2e-16 ***
ORIGIN_SZBKSZ07       5.470e-01  5.148e-03   106.257  < 2e-16 ***
ORIGIN_SZBKSZ08      -5.322e-02  6.146e-03    -8.659  < 2e-16 ***
ORIGIN_SZBKSZ09      -1.653e-01  6.730e-03   -24.556  < 2e-16 ***
ORIGIN_SZBLSZ01      -1.787e+00  1.766e-02  -101.197  < 2e-16 ***
ORIGIN_SZBLSZ02      -1.989e+00  2.139e-02   -92.981  < 2e-16 ***
ORIGIN_SZBLSZ03      -2.955e+00  5.358e-02   -55.156  < 2e-16 ***
ORIGIN_SZBLSZ04      -1.518e+00  2.547e-02   -59.604  < 2e-16 ***
ORIGIN_SZBMSZ01       1.656e-01  6.056e-03    27.341  < 2e-16 ***
ORIGIN_SZBMSZ02      -1.417e+00  7.824e-03  -181.074  < 2e-16 ***
ORIGIN_SZBMSZ03      -6.150e-01  6.381e-03   -96.391  < 2e-16 ***
ORIGIN_SZBMSZ04      -5.629e-01  5.906e-03   -95.321  < 2e-16 ***
ORIGIN_SZBMSZ05      -3.121e+00  1.881e-02  -165.912  < 2e-16 ***
ORIGIN_SZBMSZ06      -3.040e+00  1.943e-02  -156.427  < 2e-16 ***
ORIGIN_SZBMSZ07      -7.571e-01  6.686e-03  -113.233  < 2e-16 ***
ORIGIN_SZBMSZ08      -9.476e-01  6.719e-03  -141.045  < 2e-16 ***
ORIGIN_SZBMSZ09      -1.422e+00  1.011e-02  -140.664  < 2e-16 ***
ORIGIN_SZBMSZ10      -1.723e+00  1.016e-02  -169.658  < 2e-16 ***
ORIGIN_SZBMSZ11      -1.259e+00  7.679e-03  -163.980  < 2e-16 ***
ORIGIN_SZBMSZ12      -1.393e+00  1.098e-02  -126.887  < 2e-16 ***
ORIGIN_SZBMSZ13      -4.550e-01  6.933e-03   -65.631  < 2e-16 ***
ORIGIN_SZBMSZ14      -1.016e+00  7.630e-03  -133.192  < 2e-16 ***
ORIGIN_SZBMSZ15      -6.720e-01  6.896e-03   -97.450  < 2e-16 ***
ORIGIN_SZBMSZ16      -1.544e+00  1.053e-02  -146.623  < 2e-16 ***
ORIGIN_SZBMSZ17      -1.671e+00  1.807e-02   -92.489  < 2e-16 ***
ORIGIN_SZBPSZ01       1.567e-01  6.473e-03    24.204  < 2e-16 ***
ORIGIN_SZBPSZ02      -3.516e-01  7.390e-03   -47.580  < 2e-16 ***
ORIGIN_SZBPSZ03      -1.487e-01  7.223e-03   -20.586  < 2e-16 ***
ORIGIN_SZBPSZ04       4.529e-01  5.842e-03    77.525  < 2e-16 ***
ORIGIN_SZBPSZ05       5.035e-01  5.368e-03    93.798  < 2e-16 ***
ORIGIN_SZBPSZ06      -1.009e+00  1.056e-02   -95.539  < 2e-16 ***
ORIGIN_SZBPSZ07      -3.919e-01  9.856e-03   -39.757  < 2e-16 ***
ORIGIN_SZBSSZ01       1.427e-01  6.550e-03    21.784  < 2e-16 ***
ORIGIN_SZBSSZ02       4.272e-01  5.589e-03    76.432  < 2e-16 ***
ORIGIN_SZBSSZ03      -2.457e-01  6.202e-03   -39.616  < 2e-16 ***
ORIGIN_SZBTSZ01       1.946e-01  6.667e-03    29.188  < 2e-16 ***
ORIGIN_SZBTSZ02      -4.649e-01  9.078e-03   -51.214  < 2e-16 ***
ORIGIN_SZBTSZ03      -2.809e-01  7.794e-03   -36.039  < 2e-16 ***
ORIGIN_SZBTSZ04      -1.118e+00  1.152e-02   -97.035  < 2e-16 ***
ORIGIN_SZBTSZ05      -1.016e+00  1.326e-02   -76.661  < 2e-16 ***
ORIGIN_SZBTSZ06      -1.097e+00  1.022e-02  -107.309  < 2e-16 ***
ORIGIN_SZBTSZ07      -2.326e+00  1.585e-02  -146.776  < 2e-16 ***
ORIGIN_SZBTSZ08      -1.173e+00  1.212e-02   -96.810  < 2e-16 ***
ORIGIN_SZCBSZ01      -1.104e+00  5.778e-02   -19.107  < 2e-16 ***
ORIGIN_SZCCSZ01      -8.153e-01  1.526e-02   -53.416  < 2e-16 ***
ORIGIN_SZCHSZ01       3.810e-02  1.332e-02     2.860 0.004242 ** 
ORIGIN_SZCHSZ02      -6.439e-01  9.639e-03   -66.804  < 2e-16 ***
ORIGIN_SZCHSZ03       1.676e+00  6.956e-03   240.919  < 2e-16 ***
ORIGIN_SZCKSZ01       8.808e-02  5.993e-03    14.695  < 2e-16 ***
ORIGIN_SZCKSZ02       4.422e-01  6.229e-03    70.999  < 2e-16 ***
ORIGIN_SZCKSZ03       8.014e-01  5.189e-03   154.436  < 2e-16 ***
ORIGIN_SZCKSZ04       1.276e+00  5.317e-03   239.971  < 2e-16 ***
ORIGIN_SZCKSZ05       9.428e-01  6.180e-03   152.546  < 2e-16 ***
ORIGIN_SZCKSZ06       4.034e-01  8.564e-03    47.106  < 2e-16 ***
ORIGIN_SZCLSZ01      -7.581e-01  9.466e-03   -80.088  < 2e-16 ***
ORIGIN_SZCLSZ02      -1.392e+00  1.533e-02   -90.838  < 2e-16 ***
ORIGIN_SZCLSZ03      -8.043e-01  9.101e-03   -88.372  < 2e-16 ***
ORIGIN_SZCLSZ04       8.306e-01  5.125e-03   162.063  < 2e-16 ***
ORIGIN_SZCLSZ05      -1.665e+00  1.661e-02  -100.234  < 2e-16 ***
ORIGIN_SZCLSZ06       9.334e-01  4.818e-03   193.746  < 2e-16 ***
ORIGIN_SZCLSZ07      -2.697e-01  6.462e-03   -41.740  < 2e-16 ***
ORIGIN_SZCLSZ08       1.239e-01  6.929e-03    17.887  < 2e-16 ***
ORIGIN_SZCLSZ09      -1.394e+00  1.927e-02   -72.305  < 2e-16 ***
ORIGIN_SZDTSZ02      -3.786e+00  8.713e-02   -43.454  < 2e-16 ***
ORIGIN_SZDTSZ03      -3.861e+00  8.402e-02   -45.957  < 2e-16 ***
ORIGIN_SZDTSZ13      -3.000e+00  3.492e-02   -85.912  < 2e-16 ***
ORIGIN_SZGLSZ01      -1.517e+00  1.101e-02  -137.752  < 2e-16 ***
ORIGIN_SZGLSZ02       2.352e-01  5.874e-03    40.033  < 2e-16 ***
ORIGIN_SZGLSZ03       1.927e-01  6.199e-03    31.082  < 2e-16 ***
ORIGIN_SZGLSZ04       1.021e+00  4.903e-03   208.246  < 2e-16 ***
ORIGIN_SZGLSZ05       9.840e-01  5.090e-03   193.324  < 2e-16 ***
ORIGIN_SZHGSZ01       3.135e-01  5.431e-03    57.729  < 2e-16 ***
ORIGIN_SZHGSZ02       3.752e-01  5.456e-03    68.763  < 2e-16 ***
ORIGIN_SZHGSZ03       2.425e-01  5.924e-03    40.942  < 2e-16 ***
ORIGIN_SZHGSZ04       8.772e-01  4.964e-03   176.718  < 2e-16 ***
ORIGIN_SZHGSZ05       1.176e+00  4.947e-03   237.769  < 2e-16 ***
ORIGIN_SZHGSZ06      -4.019e-02  6.380e-03    -6.298 3.01e-10 ***
ORIGIN_SZHGSZ07       4.473e-01  5.514e-03    81.117  < 2e-16 ***
ORIGIN_SZHGSZ08       2.200e-01  6.128e-03    35.903  < 2e-16 ***
ORIGIN_SZHGSZ09      -1.683e+00  8.447e-03  -199.258  < 2e-16 ***
ORIGIN_SZHGSZ10      -3.025e+00  5.010e-02   -60.370  < 2e-16 ***
ORIGIN_SZJESZ01       3.834e-01  5.627e-03    68.136  < 2e-16 ***
ORIGIN_SZJESZ02       1.093e-01  5.686e-03    19.225  < 2e-16 ***
ORIGIN_SZJESZ03       1.542e-03  6.101e-03     0.253 0.800529    
ORIGIN_SZJESZ04      -1.369e+00  1.172e-02  -116.825  < 2e-16 ***
ORIGIN_SZJESZ05      -2.090e+00  1.571e-02  -133.036  < 2e-16 ***
ORIGIN_SZJESZ06       1.385e-01  5.524e-03    25.073  < 2e-16 ***
ORIGIN_SZJESZ07      -1.781e+00  1.332e-02  -133.724  < 2e-16 ***
ORIGIN_SZJESZ08      -9.407e-01  1.382e-02   -68.066  < 2e-16 ***
ORIGIN_SZJESZ09       5.856e-01  6.037e-03    96.995  < 2e-16 ***
ORIGIN_SZJESZ10      -1.221e+00  2.332e-02   -52.336  < 2e-16 ***
ORIGIN_SZJESZ11      -1.432e+00  2.209e-02   -64.820  < 2e-16 ***
ORIGIN_SZJWSZ01       5.911e-01  7.774e-03    76.041  < 2e-16 ***
ORIGIN_SZJWSZ02       9.712e-01  5.303e-03   183.139  < 2e-16 ***
ORIGIN_SZJWSZ03       1.314e+00  4.907e-03   267.710  < 2e-16 ***
ORIGIN_SZJWSZ04       5.342e-01  5.782e-03    92.398  < 2e-16 ***
ORIGIN_SZJWSZ05      -1.580e+00  1.469e-02  -107.539  < 2e-16 ***
ORIGIN_SZJWSZ06      -9.191e-01  1.269e-02   -72.413  < 2e-16 ***
ORIGIN_SZJWSZ07      -2.314e+00  3.578e-02   -64.677  < 2e-16 ***
ORIGIN_SZJWSZ08       1.999e+00  4.798e-03   416.564  < 2e-16 ***
ORIGIN_SZJWSZ09       1.893e+00  4.527e-03   418.059  < 2e-16 ***
ORIGIN_SZKLSZ01       2.651e-01  5.691e-03    46.584  < 2e-16 ***
ORIGIN_SZKLSZ02      -6.551e-01  7.452e-03   -87.913  < 2e-16 ***
ORIGIN_SZKLSZ03      -4.120e-01  6.721e-03   -61.295  < 2e-16 ***
ORIGIN_SZKLSZ04      -2.154e+00  1.384e-02  -155.628  < 2e-16 ***
ORIGIN_SZKLSZ05      -1.117e+00  1.215e-02   -91.947  < 2e-16 ***
ORIGIN_SZKLSZ06      -5.679e+00  1.857e-01   -30.575  < 2e-16 ***
ORIGIN_SZKLSZ07      -1.204e+00  9.683e-03  -124.389  < 2e-16 ***
ORIGIN_SZKLSZ08      -1.709e+00  1.143e-02  -149.493  < 2e-16 ***
ORIGIN_SZLKSZ01      -1.690e+00  4.464e-02   -37.864  < 2e-16 ***
ORIGIN_SZMDSZ01      -1.155e+00  3.188e-02   -36.226  < 2e-16 ***
ORIGIN_SZMDSZ02      -5.117e-01  1.166e-02   -43.866  < 2e-16 ***
ORIGIN_SZMDSZ03      -1.910e+00  1.983e-02   -96.312  < 2e-16 ***
ORIGIN_SZMPSZ01      -5.297e-01  9.420e-03   -56.234  < 2e-16 ***
ORIGIN_SZMPSZ02      -2.862e-01  7.797e-03   -36.701  < 2e-16 ***
ORIGIN_SZMPSZ03       3.316e-01  6.372e-03    52.039  < 2e-16 ***
ORIGIN_SZMUSZ02      -3.834e+00  1.105e-01   -34.691  < 2e-16 ***
ORIGIN_SZNTSZ01      -2.994e+00  3.970e-02   -75.418  < 2e-16 ***
ORIGIN_SZNTSZ02      -3.225e+00  2.495e-02  -129.268  < 2e-16 ***
ORIGIN_SZNTSZ03      -1.005e+00  8.542e-03  -117.664  < 2e-16 ***
ORIGIN_SZNTSZ05      -4.286e+00  5.797e-02   -73.933  < 2e-16 ***
ORIGIN_SZNTSZ06      -4.639e+00  5.835e-02   -79.508  < 2e-16 ***
ORIGIN_SZNVSZ01       3.075e-01  5.294e-03    58.073  < 2e-16 ***
ORIGIN_SZNVSZ02      -5.582e-01  7.374e-03   -75.697  < 2e-16 ***
ORIGIN_SZNVSZ03      -1.010e+00  9.056e-03  -111.478  < 2e-16 ***
ORIGIN_SZNVSZ04      -8.440e-01  9.959e-03   -84.750  < 2e-16 ***
ORIGIN_SZNVSZ05      -2.148e+00  1.824e-02  -117.754  < 2e-16 ***
ORIGIN_SZPGSZ01      -5.425e-01  1.515e-02   -35.803  < 2e-16 ***
ORIGIN_SZPGSZ02      -3.894e-01  8.513e-03   -45.738  < 2e-16 ***
ORIGIN_SZPGSZ03       7.077e-01  5.553e-03   127.437  < 2e-16 ***
ORIGIN_SZPGSZ04       1.234e+00  5.107e-03   241.546  < 2e-16 ***
ORIGIN_SZPGSZ05       4.080e-01  6.984e-03    58.410  < 2e-16 ***
ORIGIN_SZPLSZ01      -5.507e-01  1.345e-02   -40.952  < 2e-16 ***
ORIGIN_SZPLSZ02      -1.002e+00  1.723e-02   -58.153  < 2e-16 ***
ORIGIN_SZPLSZ03      -1.726e+00  4.726e-02   -36.524  < 2e-16 ***
ORIGIN_SZPLSZ04      -2.205e+00  3.736e-02   -59.024  < 2e-16 ***
ORIGIN_SZPLSZ05      -1.710e+00  2.609e-02   -65.537  < 2e-16 ***
ORIGIN_SZPNSZ01       1.489e+00  5.515e-03   270.096  < 2e-16 ***
ORIGIN_SZPNSZ02       6.893e-01  1.278e-02    53.923  < 2e-16 ***
ORIGIN_SZPNSZ03      -1.416e+00  2.162e-02   -65.496  < 2e-16 ***
ORIGIN_SZPNSZ04      -2.060e+00  3.607e-02   -57.104  < 2e-16 ***
ORIGIN_SZPNSZ05      -9.722e-01  3.210e-02   -30.289  < 2e-16 ***
ORIGIN_SZPRSZ01       6.116e-02  1.391e-02     4.396 1.10e-05 ***
ORIGIN_SZPRSZ02       1.305e+00  5.381e-03   242.598  < 2e-16 ***
ORIGIN_SZPRSZ03       1.002e+00  5.429e-03   184.636  < 2e-16 ***
ORIGIN_SZPRSZ04      -2.500e-02  8.801e-03    -2.840 0.004511 ** 
ORIGIN_SZPRSZ05       1.685e+00  5.084e-03   331.530  < 2e-16 ***
ORIGIN_SZPRSZ06      -8.502e-01  1.313e-02   -64.756  < 2e-16 ***
ORIGIN_SZPRSZ07      -2.199e+00  1.774e-02  -123.982  < 2e-16 ***
ORIGIN_SZPRSZ08       4.520e-01  7.261e-03    62.252  < 2e-16 ***
ORIGIN_SZQTSZ01      -3.688e-01  7.877e-03   -46.819  < 2e-16 ***
ORIGIN_SZQTSZ02      -8.373e-01  7.154e-03  -117.032  < 2e-16 ***
ORIGIN_SZQTSZ03      -2.607e-01  6.556e-03   -39.763  < 2e-16 ***
ORIGIN_SZQTSZ04      -1.240e+00  8.405e-03  -147.512  < 2e-16 ***
ORIGIN_SZQTSZ05      -7.392e-01  7.236e-03  -102.161  < 2e-16 ***
ORIGIN_SZQTSZ06      -6.805e-01  7.666e-03   -88.773  < 2e-16 ***
ORIGIN_SZQTSZ07      -1.461e+00  1.094e-02  -133.600  < 2e-16 ***
ORIGIN_SZQTSZ08      -3.004e-01  7.019e-03   -42.805  < 2e-16 ***
ORIGIN_SZQTSZ09      -6.296e-01  7.874e-03   -79.959  < 2e-16 ***
ORIGIN_SZQTSZ10      -3.463e-01  7.545e-03   -45.897  < 2e-16 ***
ORIGIN_SZQTSZ11      -1.983e+00  1.512e-02  -131.141  < 2e-16 ***
ORIGIN_SZQTSZ12      -2.683e+00  2.059e-02  -130.356  < 2e-16 ***
ORIGIN_SZQTSZ13      -4.182e-01  8.841e-03   -47.306  < 2e-16 ***
ORIGIN_SZQTSZ14      -1.683e+00  1.344e-02  -125.226  < 2e-16 ***
ORIGIN_SZQTSZ15      -3.718e-01  1.319e-02   -28.177  < 2e-16 ***
ORIGIN_SZRCSZ01      -1.720e+00  1.412e-02  -121.849  < 2e-16 ***
ORIGIN_SZRCSZ06      -1.165e+00  9.489e-03  -122.735  < 2e-16 ***
ORIGIN_SZRVSZ01      -3.053e+00  3.397e-02   -89.862  < 2e-16 ***
ORIGIN_SZRVSZ02      -3.631e+00  2.976e-02  -121.982  < 2e-16 ***
ORIGIN_SZRVSZ03      -3.261e+00  2.591e-02  -125.820  < 2e-16 ***
ORIGIN_SZRVSZ04      -3.764e+00  5.759e-02   -65.350  < 2e-16 ***
ORIGIN_SZRVSZ05      -2.977e+00  1.786e-02  -166.704  < 2e-16 ***
ORIGIN_SZSBSZ01       2.817e-02  7.856e-03     3.586 0.000336 ***
ORIGIN_SZSBSZ02      -5.725e-01  9.305e-03   -61.526  < 2e-16 ***
ORIGIN_SZSBSZ03       8.912e-01  5.459e-03   163.267  < 2e-16 ***
ORIGIN_SZSBSZ04       8.291e-01  6.190e-03   133.936  < 2e-16 ***
ORIGIN_SZSBSZ05      -1.657e-01  7.834e-03   -21.149  < 2e-16 ***
ORIGIN_SZSBSZ06      -1.142e+00  1.964e-02   -58.132  < 2e-16 ***
ORIGIN_SZSBSZ07      -8.886e-01  1.607e-02   -55.289  < 2e-16 ***
ORIGIN_SZSBSZ08      -1.137e+00  1.746e-02   -65.107  < 2e-16 ***
ORIGIN_SZSBSZ09      -5.911e-01  1.020e-02   -57.971  < 2e-16 ***
ORIGIN_SZSESZ02       1.130e+00  5.094e-03   221.775  < 2e-16 ***
ORIGIN_SZSESZ03       1.119e+00  4.902e-03   228.273  < 2e-16 ***
ORIGIN_SZSESZ04       7.530e-01  5.695e-03   132.233  < 2e-16 ***
ORIGIN_SZSESZ05      -2.681e-01  6.959e-03   -38.530  < 2e-16 ***
ORIGIN_SZSESZ06       8.151e-01  5.580e-03   146.077  < 2e-16 ***
ORIGIN_SZSESZ07      -2.285e+00  2.312e-02   -98.840  < 2e-16 ***
ORIGIN_SZSGSZ01      -7.290e-01  9.896e-03   -73.669  < 2e-16 ***
ORIGIN_SZSGSZ02      -1.111e+00  1.109e-02  -100.124  < 2e-16 ***
ORIGIN_SZSGSZ03       1.781e-01  6.051e-03    29.441  < 2e-16 ***
ORIGIN_SZSGSZ04       3.793e-01  5.617e-03    67.533  < 2e-16 ***
ORIGIN_SZSGSZ05      -1.718e+00  1.189e-02  -144.416  < 2e-16 ***
ORIGIN_SZSGSZ06       4.625e-01  5.289e-03    87.452  < 2e-16 ***
ORIGIN_SZSGSZ07      -7.111e-01  7.313e-03   -97.240  < 2e-16 ***
ORIGIN_SZSKSZ01       1.757e-01  1.007e-02    17.443  < 2e-16 ***
ORIGIN_SZSKSZ02       1.237e+00  6.351e-03   194.744  < 2e-16 ***
ORIGIN_SZSKSZ03      -3.102e-01  9.679e-03   -32.053  < 2e-16 ***
ORIGIN_SZSKSZ04      -1.826e+00  3.592e-02   -50.819  < 2e-16 ***
ORIGIN_SZSKSZ05      -4.231e-01  1.767e-02   -23.943  < 2e-16 ***
ORIGIN_SZSLSZ01      -2.596e+00  3.480e-02   -74.596  < 2e-16 ***
ORIGIN_SZSLSZ04      -2.146e-01  8.852e-03   -24.249  < 2e-16 ***
ORIGIN_SZSRSZ01      -2.981e+00  1.736e-02  -171.687  < 2e-16 ***
ORIGIN_SZTHSZ01      -1.978e+00  5.703e-02   -34.689  < 2e-16 ***
ORIGIN_SZTHSZ03      -1.750e+00  2.728e-02   -64.141  < 2e-16 ***
ORIGIN_SZTHSZ04      -2.769e+00  3.432e-02   -80.678  < 2e-16 ***
ORIGIN_SZTHSZ06      -2.184e+00  2.055e-02  -106.298  < 2e-16 ***
ORIGIN_SZTMSZ01       8.343e-01  6.682e-03   124.847  < 2e-16 ***
ORIGIN_SZTMSZ02       2.321e+00  4.498e-03   515.896  < 2e-16 ***
ORIGIN_SZTMSZ03       1.709e+00  4.862e-03   351.580  < 2e-16 ***
ORIGIN_SZTMSZ04       1.248e+00  5.839e-03   213.680  < 2e-16 ***
ORIGIN_SZTMSZ05      -8.754e-02  1.241e-02    -7.055 1.72e-12 ***
ORIGIN_SZTNSZ01      -2.059e+00  1.396e-02  -147.516  < 2e-16 ***
ORIGIN_SZTNSZ02      -1.892e+00  1.079e-02  -175.317  < 2e-16 ***
ORIGIN_SZTNSZ03      -2.184e+00  1.468e-02  -148.846  < 2e-16 ***
ORIGIN_SZTNSZ04      -5.183e-01  8.150e-03   -63.595  < 2e-16 ***
ORIGIN_SZTPSZ01      -6.802e-01  7.561e-03   -89.963  < 2e-16 ***
ORIGIN_SZTPSZ02       4.469e-01  5.019e-03    89.042  < 2e-16 ***
ORIGIN_SZTPSZ03      -7.869e-01  7.225e-03  -108.911  < 2e-16 ***
ORIGIN_SZTPSZ04      -7.108e-01  6.646e-03  -106.946  < 2e-16 ***
ORIGIN_SZTPSZ05      -5.636e-01  7.037e-03   -80.084  < 2e-16 ***
ORIGIN_SZTPSZ06      -4.351e-01  6.871e-03   -63.322  < 2e-16 ***
ORIGIN_SZTPSZ07      -2.877e-01  7.103e-03   -40.510  < 2e-16 ***
ORIGIN_SZTPSZ08      -1.091e+00  1.100e-02   -99.143  < 2e-16 ***
ORIGIN_SZTPSZ09      -8.156e-01  7.916e-03  -103.027  < 2e-16 ***
ORIGIN_SZTPSZ10      -9.365e-01  8.681e-03  -107.877  < 2e-16 ***
ORIGIN_SZTPSZ11      -5.242e-02  6.434e-03    -8.147 3.72e-16 ***
ORIGIN_SZTPSZ12      -6.372e-01  7.832e-03   -81.353  < 2e-16 ***
ORIGIN_SZTSSZ01      -1.821e+00  5.174e-02   -35.203  < 2e-16 ***
ORIGIN_SZTSSZ02       1.121e+00  9.420e-03   119.037  < 2e-16 ***
ORIGIN_SZTSSZ03       6.082e-01  9.592e-03    63.403  < 2e-16 ***
ORIGIN_SZTSSZ04       8.172e-01  1.050e-02    77.844  < 2e-16 ***
ORIGIN_SZTSSZ05       4.000e-02  1.787e-02     2.238 0.025209 *  
ORIGIN_SZTSSZ06       1.705e+00  2.068e-02    82.420  < 2e-16 ***
ORIGIN_SZWCSZ01       8.029e-01  1.056e-02    76.008  < 2e-16 ***
ORIGIN_SZWCSZ02      -1.991e+00  3.457e-02   -57.589  < 2e-16 ***
ORIGIN_SZWCSZ03      -5.068e+00  1.475e-01   -34.359  < 2e-16 ***
ORIGIN_SZWDSZ01       1.492e+00  4.722e-03   316.015  < 2e-16 ***
ORIGIN_SZWDSZ02       9.860e-01  5.577e-03   176.779  < 2e-16 ***
ORIGIN_SZWDSZ03       1.588e+00  5.219e-03   304.180  < 2e-16 ***
ORIGIN_SZWDSZ04       1.382e+00  6.052e-03   228.327  < 2e-16 ***
ORIGIN_SZWDSZ05       6.605e-01  6.229e-03   106.026  < 2e-16 ***
ORIGIN_SZWDSZ06       7.977e-01  6.096e-03   130.865  < 2e-16 ***
ORIGIN_SZWDSZ07      -6.617e-01  9.357e-03   -70.722  < 2e-16 ***
ORIGIN_SZWDSZ08      -3.747e-01  9.645e-03   -38.852  < 2e-16 ***
ORIGIN_SZWDSZ09       1.418e+00  5.231e-03   271.027  < 2e-16 ***
ORIGIN_SZYSSZ01      -1.927e-01  6.955e-03   -27.704  < 2e-16 ***
ORIGIN_SZYSSZ02       8.767e-01  5.896e-03   148.707  < 2e-16 ***
ORIGIN_SZYSSZ03       1.832e+00  5.038e-03   363.581  < 2e-16 ***
ORIGIN_SZYSSZ04       1.075e+00  5.296e-03   202.917  < 2e-16 ***
ORIGIN_SZYSSZ05       3.194e-01  6.970e-03    45.820  < 2e-16 ***
ORIGIN_SZYSSZ06      -4.514e-01  1.249e-02   -36.148  < 2e-16 ***
ORIGIN_SZYSSZ07      -1.039e+00  1.558e-02   -66.651  < 2e-16 ***
ORIGIN_SZYSSZ08       1.825e-01  7.094e-03    25.733  < 2e-16 ***
ORIGIN_SZYSSZ09       1.066e+00  5.045e-03   211.299  < 2e-16 ***
log(DESTIN_AGE25_64)  8.299e-03  3.958e-05   209.686  < 2e-16 ***
log(dist)            -1.705e+00  4.626e-04 -3686.082  < 2e-16 ***
---
Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

(Dispersion parameter for poisson family taken to be 1)

    Null deviance: 36117615  on 14273  degrees of freedom
Residual deviance: 13020597  on 13993  degrees of freedom
AIC: 13105714

Number of Fisher Scoring iterations: 6

We can examine how the constraints hold for destinations this time.

CalcRSquared(orcSIM$data$TRIPS, orcSIM$fitted.values)
[1] 0.3983045

Destination constrained

In this section, we will fit a destination constrained SIM by using the code chunk below.

The general formula of Destination Constrained Spatial Interaction Model

lambda_ij = exp(k + mu ln V_i + alpha_i - Beta ln d_ij)

decSIM <- glm(formula = TRIPS ~ 
                DESTIN_SZ + 
                log(ORIGIN_AGE25_64) + 
                log(dist),
              family = poisson(link = "log"),
              data = SIM_data,
              na.action = na.exclude)
summary(decSIM)

Call:
glm(formula = TRIPS ~ DESTIN_SZ + log(ORIGIN_AGE25_64) + log(dist), 
    family = poisson(link = "log"), data = SIM_data, na.action = na.exclude)

Coefficients:
                       Estimate Std. Error   z value Pr(>|z|)    
(Intercept)           2.078e+01  4.880e-03  4257.201  < 2e-16 ***
DESTIN_SZAMSZ02       1.015e-01  4.974e-03    20.401  < 2e-16 ***
DESTIN_SZAMSZ03       5.837e-02  4.986e-03    11.707  < 2e-16 ***
DESTIN_SZAMSZ04      -1.167e+00  7.425e-03  -157.154  < 2e-16 ***
DESTIN_SZAMSZ05      -1.274e+00  7.585e-03  -167.972  < 2e-16 ***
DESTIN_SZAMSZ06      -1.186e+00  7.347e-03  -161.383  < 2e-16 ***
DESTIN_SZAMSZ07      -1.582e+00  1.095e-02  -144.515  < 2e-16 ***
DESTIN_SZAMSZ08      -4.466e-01  7.415e-03   -60.231  < 2e-16 ***
DESTIN_SZAMSZ09      -1.059e+00  7.680e-03  -137.875  < 2e-16 ***
DESTIN_SZAMSZ10      -1.808e-02  5.176e-03    -3.494 0.000476 ***
DESTIN_SZAMSZ11      -4.071e-01  9.487e-03   -42.914  < 2e-16 ***
DESTIN_SZAMSZ12       5.159e-01  5.324e-03    96.888  < 2e-16 ***
DESTIN_SZBDSZ01       1.066e+00  4.423e-03   241.113  < 2e-16 ***
DESTIN_SZBDSZ02       2.891e-01  5.956e-03    48.533  < 2e-16 ***
DESTIN_SZBDSZ03       3.695e-01  5.372e-03    68.784  < 2e-16 ***
DESTIN_SZBDSZ04       1.291e+00  4.311e-03   299.410  < 2e-16 ***
DESTIN_SZBDSZ05       8.675e-01  4.636e-03   187.137  < 2e-16 ***
DESTIN_SZBDSZ06       5.439e-01  5.373e-03   101.231  < 2e-16 ***
DESTIN_SZBDSZ07      -5.201e-01  1.105e-02   -47.080  < 2e-16 ***
DESTIN_SZBDSZ08      -1.180e+00  1.286e-02   -91.708  < 2e-16 ***
DESTIN_SZBKSZ01      -1.036e+00  7.777e-03  -133.177  < 2e-16 ***
DESTIN_SZBKSZ02      -3.960e-01  6.671e-03   -59.363  < 2e-16 ***
DESTIN_SZBKSZ03      -6.872e-01  6.651e-03  -103.317  < 2e-16 ***
DESTIN_SZBKSZ04      -3.992e-01  5.831e-03   -68.466  < 2e-16 ***
DESTIN_SZBKSZ05      -9.217e-01  7.387e-03  -124.783  < 2e-16 ***
DESTIN_SZBKSZ06      -9.486e-01  6.863e-03  -138.225  < 2e-16 ***
DESTIN_SZBKSZ07      -3.611e-02  4.841e-03    -7.459 8.70e-14 ***
DESTIN_SZBKSZ08      -1.276e+00  7.918e-03  -161.203  < 2e-16 ***
DESTIN_SZBKSZ09      -7.783e-02  5.428e-03   -14.338  < 2e-16 ***
DESTIN_SZBLSZ01      -3.399e-01  8.203e-03   -41.433  < 2e-16 ***
DESTIN_SZBLSZ02       5.471e-01  7.460e-03    73.333  < 2e-16 ***
DESTIN_SZBLSZ03       1.841e+00  8.494e-03   216.695  < 2e-16 ***
DESTIN_SZBLSZ04      -1.884e-01  1.722e-02   -10.942  < 2e-16 ***
DESTIN_SZBMSZ01      -1.248e-01  5.528e-03   -22.584  < 2e-16 ***
DESTIN_SZBMSZ02      -9.307e-01  5.404e-03  -172.238  < 2e-16 ***
DESTIN_SZBMSZ03      -1.264e+00  6.371e-03  -198.439  < 2e-16 ***
DESTIN_SZBMSZ04      -1.224e+00  5.773e-03  -211.973  < 2e-16 ***
DESTIN_SZBMSZ05      -1.206e+00  7.870e-03  -153.282  < 2e-16 ***
DESTIN_SZBMSZ06      -2.415e+00  1.551e-02  -155.693  < 2e-16 ***
DESTIN_SZBMSZ07      -3.868e-01  5.191e-03   -74.504  < 2e-16 ***
DESTIN_SZBMSZ08      -1.799e+00  7.183e-03  -250.377  < 2e-16 ***
DESTIN_SZBMSZ09      -3.142e+00  1.600e-02  -196.405  < 2e-16 ***
DESTIN_SZBMSZ10      -2.332e+00  9.690e-03  -240.688  < 2e-16 ***
DESTIN_SZBMSZ11      -2.057e+00  8.644e-03  -237.987  < 2e-16 ***
DESTIN_SZBMSZ12      -1.610e+00  8.965e-03  -179.532  < 2e-16 ***
DESTIN_SZBMSZ13      -6.904e-01  5.994e-03  -115.170  < 2e-16 ***
DESTIN_SZBMSZ14      -1.815e+00  8.485e-03  -213.858  < 2e-16 ***
DESTIN_SZBMSZ15      -1.638e+00  7.995e-03  -204.916  < 2e-16 ***
DESTIN_SZBMSZ16      -2.327e+00  1.309e-02  -177.854  < 2e-16 ***
DESTIN_SZBMSZ17      -2.376e+00  1.849e-02  -128.521  < 2e-16 ***
DESTIN_SZBPSZ01      -8.188e-01  6.517e-03  -125.640  < 2e-16 ***
DESTIN_SZBPSZ02      -1.707e+00  9.575e-03  -178.324  < 2e-16 ***
DESTIN_SZBPSZ03      -1.360e+00  9.089e-03  -149.657  < 2e-16 ***
DESTIN_SZBPSZ04      -5.116e-01  6.650e-03   -76.945  < 2e-16 ***
DESTIN_SZBPSZ05       3.449e-01  4.640e-03    74.327  < 2e-16 ***
DESTIN_SZBPSZ06      -8.335e-01  9.079e-03   -91.804  < 2e-16 ***
DESTIN_SZBPSZ07      -6.838e-02  8.970e-03    -7.623 2.49e-14 ***
DESTIN_SZBSSZ01       5.676e-02  5.573e-03    10.185  < 2e-16 ***
DESTIN_SZBSSZ02      -7.178e-01  6.384e-03  -112.432  < 2e-16 ***
DESTIN_SZBSSZ03       1.454e-01  4.669e-03    31.150  < 2e-16 ***
DESTIN_SZBTSZ01       4.750e-01  4.797e-03    99.023  < 2e-16 ***
DESTIN_SZBTSZ02      -1.896e-01  7.826e-03   -24.233  < 2e-16 ***
DESTIN_SZBTSZ03       7.173e-02  5.942e-03    12.072  < 2e-16 ***
DESTIN_SZBTSZ04      -1.411e+00  1.220e-02  -115.626  < 2e-16 ***
DESTIN_SZBTSZ05      -3.726e-01  8.175e-03   -45.581  < 2e-16 ***
DESTIN_SZBTSZ06      -9.464e-01  8.139e-03  -116.285  < 2e-16 ***
DESTIN_SZBTSZ07      -1.989e+00  1.212e-02  -164.074  < 2e-16 ***
DESTIN_SZBTSZ08      -1.697e+00  1.167e-02  -145.321  < 2e-16 ***
DESTIN_SZCBSZ01      -3.574e+00  3.334e-01   -10.720  < 2e-16 ***
DESTIN_SZCCSZ01      -2.963e-01  9.377e-03   -31.594  < 2e-16 ***
DESTIN_SZCHSZ01      -1.637e-01  1.131e-02   -14.483  < 2e-16 ***
DESTIN_SZCHSZ02      -1.464e-01  6.320e-03   -23.166  < 2e-16 ***
DESTIN_SZCHSZ03       2.555e+00  4.645e-03   550.084  < 2e-16 ***
DESTIN_SZCKSZ01       7.760e-02  5.380e-03    14.423  < 2e-16 ***
DESTIN_SZCKSZ02      -3.345e-01  6.067e-03   -55.135  < 2e-16 ***
DESTIN_SZCKSZ03       5.907e-01  4.491e-03   131.521  < 2e-16 ***
DESTIN_SZCKSZ04      -4.018e-01  7.384e-03   -54.422  < 2e-16 ***
DESTIN_SZCKSZ05      -3.418e-01  7.726e-03   -44.239  < 2e-16 ***
DESTIN_SZCKSZ06       2.795e-01  7.425e-03    37.650  < 2e-16 ***
DESTIN_SZCLSZ01       2.352e-01  5.236e-03    44.923  < 2e-16 ***
DESTIN_SZCLSZ02      -1.989e+00  1.477e-02  -134.698  < 2e-16 ***
DESTIN_SZCLSZ03      -6.967e-01  8.678e-03   -80.285  < 2e-16 ***
DESTIN_SZCLSZ04      -2.149e-01  5.421e-03   -39.649  < 2e-16 ***
DESTIN_SZCLSZ05      -9.615e-01  9.601e-03  -100.149  < 2e-16 ***
DESTIN_SZCLSZ06       1.155e-01  4.815e-03    23.982  < 2e-16 ***
DESTIN_SZCLSZ07      -6.519e-01  6.227e-03  -104.696  < 2e-16 ***
DESTIN_SZCLSZ08      -4.505e-01  6.839e-03   -65.875  < 2e-16 ***
DESTIN_SZCLSZ09       2.206e-01  7.262e-03    30.380  < 2e-16 ***
DESTIN_SZDTSZ02      -2.608e+00  3.734e-02   -69.850  < 2e-16 ***
DESTIN_SZDTSZ03      -1.093e+00  1.499e-02   -72.898  < 2e-16 ***
DESTIN_SZDTSZ13      -1.684e+00  1.754e-02   -96.009  < 2e-16 ***
DESTIN_SZGLSZ01      -2.825e-01  5.655e-03   -49.951  < 2e-16 ***
DESTIN_SZGLSZ02      -1.968e-01  5.554e-03   -35.429  < 2e-16 ***
DESTIN_SZGLSZ03       7.242e-01  4.493e-03   161.184  < 2e-16 ***
DESTIN_SZGLSZ04       5.340e-01  4.544e-03   117.519  < 2e-16 ***
DESTIN_SZGLSZ05       6.778e-01  4.513e-03   150.195  < 2e-16 ***
DESTIN_SZHGSZ01       3.913e-01  4.386e-03    89.221  < 2e-16 ***
DESTIN_SZHGSZ02      -6.106e-01  6.352e-03   -96.126  < 2e-16 ***
DESTIN_SZHGSZ03      -1.004e+00  7.391e-03  -135.900  < 2e-16 ***
DESTIN_SZHGSZ04      -2.100e-01  5.218e-03   -40.241  < 2e-16 ***
DESTIN_SZHGSZ05      -2.563e-01  5.545e-03   -46.221  < 2e-16 ***
DESTIN_SZHGSZ06      -7.208e-01  6.554e-03  -109.971  < 2e-16 ***
DESTIN_SZHGSZ07       1.312e-01  5.131e-03    25.567  < 2e-16 ***
DESTIN_SZHGSZ08      -1.330e-01  5.669e-03   -23.461  < 2e-16 ***
DESTIN_SZHGSZ09       1.061e-01  6.023e-03    17.612  < 2e-16 ***
DESTIN_SZHGSZ10      -3.247e+00  2.893e-02  -112.234  < 2e-16 ***
DESTIN_SZJESZ01      -7.166e-02  5.725e-03   -12.518  < 2e-16 ***
DESTIN_SZJESZ02      -5.541e-01  6.007e-03   -92.230  < 2e-16 ***
DESTIN_SZJESZ03      -6.245e-01  6.413e-03   -97.391  < 2e-16 ***
DESTIN_SZJESZ04      -7.106e-01  8.225e-03   -86.400  < 2e-16 ***
DESTIN_SZJESZ05      -1.295e+00  1.117e-02  -115.909  < 2e-16 ***
DESTIN_SZJESZ06       1.971e-01  4.681e-03    42.106  < 2e-16 ***
DESTIN_SZJESZ07      -1.239e+00  9.009e-03  -137.547  < 2e-16 ***
DESTIN_SZJESZ08      -4.837e-01  9.453e-03   -51.168  < 2e-16 ***
DESTIN_SZJESZ09      -5.870e-02  6.811e-03    -8.617  < 2e-16 ***
DESTIN_SZJESZ10       9.502e-01  8.409e-03   112.996  < 2e-16 ***
DESTIN_SZJESZ11       7.381e-01  7.625e-03    96.805  < 2e-16 ***
DESTIN_SZJWSZ01      -1.025e-01  7.621e-03   -13.450  < 2e-16 ***
DESTIN_SZJWSZ02       1.553e-02  5.940e-03     2.614 0.008956 ** 
DESTIN_SZJWSZ03       8.892e-01  4.675e-03   190.213  < 2e-16 ***
DESTIN_SZJWSZ04       6.128e-01  4.973e-03   123.228  < 2e-16 ***
DESTIN_SZJWSZ05      -4.900e-01  7.297e-03   -67.142  < 2e-16 ***
DESTIN_SZJWSZ06       3.832e-01  6.120e-03    62.615  < 2e-16 ***
DESTIN_SZJWSZ07      -9.219e-01  3.283e-02   -28.081  < 2e-16 ***
DESTIN_SZJWSZ08       8.565e-01  5.601e-03   152.914  < 2e-16 ***
DESTIN_SZJWSZ09       1.589e+00  4.033e-03   394.051  < 2e-16 ***
DESTIN_SZKLSZ01      -6.872e-01  6.356e-03  -108.133  < 2e-16 ***
DESTIN_SZKLSZ02      -7.234e-01  6.447e-03  -112.205  < 2e-16 ***
DESTIN_SZKLSZ03      -1.262e+00  7.557e-03  -167.042  < 2e-16 ***
DESTIN_SZKLSZ04      -1.775e+00  9.757e-03  -181.902  < 2e-16 ***
DESTIN_SZKLSZ05      -6.651e-01  9.372e-03   -70.970  < 2e-16 ***
DESTIN_SZKLSZ06      -3.042e+00  3.895e-02   -78.109  < 2e-16 ***
DESTIN_SZKLSZ07      -1.272e+00  7.660e-03  -166.094  < 2e-16 ***
DESTIN_SZKLSZ08      -7.530e-01  5.761e-03  -130.714  < 2e-16 ***
DESTIN_SZLKSZ01      -7.686e-01  2.687e-02   -28.610  < 2e-16 ***
DESTIN_SZMDSZ01      -8.627e-01  2.282e-02   -37.807  < 2e-16 ***
DESTIN_SZMDSZ02      -9.150e-01  1.230e-02   -74.395  < 2e-16 ***
DESTIN_SZMDSZ03      -2.721e+00  3.013e-02   -90.287  < 2e-16 ***
DESTIN_SZMPSZ01      -5.665e-01  8.720e-03   -64.972  < 2e-16 ***
DESTIN_SZMPSZ02      -5.987e-01  6.935e-03   -86.334  < 2e-16 ***
DESTIN_SZMPSZ03       2.592e-01  5.496e-03    47.167  < 2e-16 ***
DESTIN_SZMUSZ02      -2.836e+00  2.149e-02  -131.968  < 2e-16 ***
DESTIN_SZNTSZ01      -4.181e+00  5.310e-02   -78.734  < 2e-16 ***
DESTIN_SZNTSZ02      -2.239e+00  1.256e-02  -178.211  < 2e-16 ***
DESTIN_SZNTSZ03      -1.670e+00  8.541e-03  -195.526  < 2e-16 ***
DESTIN_SZNTSZ05      -2.268e+00  2.708e-02   -83.745  < 2e-16 ***
DESTIN_SZNTSZ06      -3.230e+00  5.050e-02   -63.960  < 2e-16 ***
DESTIN_SZNVSZ01      -5.315e-01  5.386e-03   -98.686  < 2e-16 ***
DESTIN_SZNVSZ02      -6.042e-01  6.040e-03  -100.034  < 2e-16 ***
DESTIN_SZNVSZ03      -5.891e-01  6.470e-03   -91.045  < 2e-16 ***
DESTIN_SZNVSZ04      -2.025e+00  1.284e-02  -157.742  < 2e-16 ***
DESTIN_SZNVSZ05      -1.552e+00  9.973e-03  -155.669  < 2e-16 ***
DESTIN_SZPGSZ01      -1.159e+00  1.743e-02   -66.470  < 2e-16 ***
DESTIN_SZPGSZ02      -7.449e-01  8.015e-03   -92.946  < 2e-16 ***
DESTIN_SZPGSZ03       2.836e-01  5.084e-03    55.779  < 2e-16 ***
DESTIN_SZPGSZ04       2.200e-01  5.356e-03    41.079  < 2e-16 ***
DESTIN_SZPGSZ05      -6.517e-01  8.887e-03   -73.327  < 2e-16 ***
DESTIN_SZPLSZ01       4.468e-02  8.043e-03     5.556 2.77e-08 ***
DESTIN_SZPLSZ02      -1.133e+00  1.526e-02   -74.247  < 2e-16 ***
DESTIN_SZPLSZ03      -1.786e-01  1.086e-02   -16.441  < 2e-16 ***
DESTIN_SZPLSZ04      -1.807e+00  1.149e-02  -157.291  < 2e-16 ***
DESTIN_SZPLSZ05      -2.666e-01  1.304e-02   -20.441  < 2e-16 ***
DESTIN_SZPNSZ01       6.990e-01  7.378e-03    94.731  < 2e-16 ***
DESTIN_SZPNSZ02       1.984e+00  7.378e-03   268.952  < 2e-16 ***
DESTIN_SZPNSZ03       9.256e-01  8.710e-03   106.259  < 2e-16 ***
DESTIN_SZPNSZ04       2.246e+00  9.179e-03   244.662  < 2e-16 ***
DESTIN_SZPNSZ05       1.493e+00  1.386e-02   107.731  < 2e-16 ***
DESTIN_SZPRSZ01      -5.696e-01  9.603e-03   -59.310  < 2e-16 ***
DESTIN_SZPRSZ02       3.458e-01  5.985e-03    57.778  < 2e-16 ***
DESTIN_SZPRSZ03       9.711e-01  4.477e-03   216.877  < 2e-16 ***
DESTIN_SZPRSZ04       9.094e-02  9.321e-03     9.757  < 2e-16 ***
DESTIN_SZPRSZ05       2.509e-01  5.826e-03    43.071  < 2e-16 ***
DESTIN_SZPRSZ06       3.659e-01  6.453e-03    56.707  < 2e-16 ***
DESTIN_SZPRSZ07      -1.900e+00  1.384e-02  -137.218  < 2e-16 ***
DESTIN_SZPRSZ08      -2.083e-01  7.484e-03   -27.831  < 2e-16 ***
DESTIN_SZQTSZ01      -1.147e+00  9.317e-03  -123.150  < 2e-16 ***
DESTIN_SZQTSZ02      -1.407e+00  8.166e-03  -172.286  < 2e-16 ***
DESTIN_SZQTSZ03      -1.439e+00  7.910e-03  -181.916  < 2e-16 ***
DESTIN_SZQTSZ04      -1.293e+00  7.736e-03  -167.091  < 2e-16 ***
DESTIN_SZQTSZ05      -1.357e+00  7.282e-03  -186.345  < 2e-16 ***
DESTIN_SZQTSZ06      -1.468e+00  7.485e-03  -196.090  < 2e-16 ***
DESTIN_SZQTSZ07      -1.790e+00  1.233e-02  -145.104  < 2e-16 ***
DESTIN_SZQTSZ08      -3.606e-01  5.838e-03   -61.770  < 2e-16 ***
DESTIN_SZQTSZ09      -9.056e-01  6.979e-03  -129.767  < 2e-16 ***
DESTIN_SZQTSZ10      -2.906e-01  6.253e-03   -46.476  < 2e-16 ***
DESTIN_SZQTSZ11      -1.233e-01  6.113e-03   -20.163  < 2e-16 ***
DESTIN_SZQTSZ12      -1.001e+00  9.023e-03  -110.913  < 2e-16 ***
DESTIN_SZQTSZ13       5.414e-03  6.518e-03     0.831 0.406179    
DESTIN_SZQTSZ14       7.865e-02  7.359e-03    10.687  < 2e-16 ***
DESTIN_SZQTSZ15       5.914e-01  8.868e-03    66.683  < 2e-16 ***
DESTIN_SZRCSZ01      -8.442e-01  7.937e-03  -106.358  < 2e-16 ***
DESTIN_SZRCSZ06      -1.499e+00  2.099e-02   -71.403  < 2e-16 ***
DESTIN_SZRVSZ01      -2.725e+00  1.758e-02  -155.021  < 2e-16 ***
DESTIN_SZRVSZ02      -2.729e+00  3.547e-02   -76.948  < 2e-16 ***
DESTIN_SZRVSZ03      -2.852e+00  1.526e-02  -186.849  < 2e-16 ***
DESTIN_SZRVSZ04      -2.419e+00  1.656e-02  -146.018  < 2e-16 ***
DESTIN_SZRVSZ05      -4.056e+00  2.982e-02  -135.985  < 2e-16 ***
DESTIN_SZSBSZ01      -1.234e+00  1.040e-02  -118.747  < 2e-16 ***
DESTIN_SZSBSZ02      -1.017e+00  8.524e-03  -119.325  < 2e-16 ***
DESTIN_SZSBSZ03       5.832e-01  5.034e-03   115.852  < 2e-16 ***
DESTIN_SZSBSZ04       5.358e-01  6.058e-03    88.433  < 2e-16 ***
DESTIN_SZSBSZ05      -1.058e+00  8.962e-03  -117.999  < 2e-16 ***
DESTIN_SZSBSZ06      -1.432e+00  2.467e-02   -58.046  < 2e-16 ***
DESTIN_SZSBSZ07       1.064e-02  2.354e-02     0.452 0.651293    
DESTIN_SZSBSZ08       1.369e+00  6.054e-03   226.181  < 2e-16 ***
DESTIN_SZSBSZ09       4.902e-01  5.659e-03    86.614  < 2e-16 ***
DESTIN_SZSESZ02      -5.833e-02  5.671e-03   -10.286  < 2e-16 ***
DESTIN_SZSESZ03       6.286e-01  4.379e-03   143.553  < 2e-16 ***
DESTIN_SZSESZ04      -5.618e-01  6.540e-03   -85.889  < 2e-16 ***
DESTIN_SZSESZ05      -2.421e-01  5.499e-03   -44.017  < 2e-16 ***
DESTIN_SZSESZ06      -3.034e-01  7.234e-03   -41.942  < 2e-16 ***
DESTIN_SZSESZ07      -2.597e+00  2.458e-02  -105.689  < 2e-16 ***
DESTIN_SZSGSZ01      -1.061e-01  6.663e-03   -15.929  < 2e-16 ***
DESTIN_SZSGSZ02      -1.121e-02  5.890e-03    -1.904 0.056946 .  
DESTIN_SZSGSZ03      -1.726e-01  5.505e-03   -31.359  < 2e-16 ***
DESTIN_SZSGSZ04      -1.043e-01  5.484e-03   -19.025  < 2e-16 ***
DESTIN_SZSGSZ05      -2.158e+00  1.138e-02  -189.582  < 2e-16 ***
DESTIN_SZSGSZ06       4.301e-01  4.384e-03    98.101  < 2e-16 ***
DESTIN_SZSGSZ07      -4.008e-01  5.925e-03   -67.637  < 2e-16 ***
DESTIN_SZSISZ01      -1.400e+00  2.886e-02   -48.525  < 2e-16 ***
DESTIN_SZSKSZ01       2.399e-01  8.292e-03    28.928  < 2e-16 ***
DESTIN_SZSKSZ02       1.423e+00  6.000e-03   237.237  < 2e-16 ***
DESTIN_SZSKSZ03       2.412e-01  6.738e-03    35.801  < 2e-16 ***
DESTIN_SZSKSZ04      -4.208e-01  1.613e-02   -26.092  < 2e-16 ***
DESTIN_SZSKSZ05       4.143e-01  1.228e-02    33.744  < 2e-16 ***
DESTIN_SZSLSZ01      -3.784e-01  9.978e-03   -37.926  < 2e-16 ***
DESTIN_SZSLSZ04      -5.051e-01  8.622e-03   -58.587  < 2e-16 ***
DESTIN_SZSRSZ01      -2.890e+00  1.387e-02  -208.405  < 2e-16 ***
DESTIN_SZTHSZ01      -3.195e+00  4.027e-02   -79.337  < 2e-16 ***
DESTIN_SZTHSZ03      -1.787e+00  2.618e-02   -68.260  < 2e-16 ***
DESTIN_SZTHSZ04      -2.611e+00  2.418e-02  -107.975  < 2e-16 ***
DESTIN_SZTHSZ06      -1.937e+00  1.661e-02  -116.675  < 2e-16 ***
DESTIN_SZTMSZ01       5.050e-01  6.307e-03    80.059  < 2e-16 ***
DESTIN_SZTMSZ02       1.903e+00  3.923e-03   485.056  < 2e-16 ***
DESTIN_SZTMSZ03       1.329e+00  4.402e-03   301.962  < 2e-16 ***
DESTIN_SZTMSZ04       1.664e+00  4.336e-03   383.693  < 2e-16 ***
DESTIN_SZTMSZ05       1.113e+00  6.327e-03   175.924  < 2e-16 ***
DESTIN_SZTNSZ01      -1.169e+00  8.031e-03  -145.511  < 2e-16 ***
DESTIN_SZTNSZ02      -2.264e+00  1.092e-02  -207.261  < 2e-16 ***
DESTIN_SZTNSZ03      -2.075e+00  1.292e-02  -160.551  < 2e-16 ***
DESTIN_SZTNSZ04      -1.094e+00  8.166e-03  -133.957  < 2e-16 ***
DESTIN_SZTPSZ01      -8.210e-01  6.877e-03  -119.392  < 2e-16 ***
DESTIN_SZTPSZ02       2.287e-01  4.284e-03    53.395  < 2e-16 ***
DESTIN_SZTPSZ03      -9.176e-01  6.547e-03  -140.154  < 2e-16 ***
DESTIN_SZTPSZ04      -1.720e+00  8.149e-03  -211.021  < 2e-16 ***
DESTIN_SZTPSZ05      -1.406e+00  6.823e-03  -206.049  < 2e-16 ***
DESTIN_SZTPSZ06      -8.429e-01  6.917e-03  -121.858  < 2e-16 ***
DESTIN_SZTPSZ07      -2.355e+00  1.308e-02  -180.009  < 2e-16 ***
DESTIN_SZTPSZ08      -1.674e+00  1.049e-02  -159.549  < 2e-16 ***
DESTIN_SZTPSZ09      -6.042e-01  7.685e-03   -78.630  < 2e-16 ***
DESTIN_SZTPSZ10      -1.558e+00  9.999e-03  -155.799  < 2e-16 ***
DESTIN_SZTPSZ11      -3.935e-01  5.983e-03   -65.766  < 2e-16 ***
DESTIN_SZTPSZ12      -8.950e-01  7.230e-03  -123.782  < 2e-16 ***
DESTIN_SZTSSZ01       4.498e-02  2.219e-02     2.027 0.042640 *  
DESTIN_SZTSSZ02       7.866e-01  1.536e-02    51.209  < 2e-16 ***
DESTIN_SZTSSZ03       1.750e+00  9.257e-03   189.027  < 2e-16 ***
DESTIN_SZTSSZ04       1.611e+00  9.010e-03   178.789  < 2e-16 ***
DESTIN_SZTSSZ05       2.539e+00  8.573e-03   296.183  < 2e-16 ***
DESTIN_SZTSSZ06       3.126e+00  1.613e-02   193.787  < 2e-16 ***
DESTIN_SZWCSZ01       3.020e+00  5.172e-03   583.855  < 2e-16 ***
DESTIN_SZWCSZ02      -6.657e-01  1.292e-02   -51.523  < 2e-16 ***
DESTIN_SZWCSZ03      -1.713e+00  3.475e-02   -49.291  < 2e-16 ***
DESTIN_SZWDSZ01       1.387e+00  3.996e-03   347.052  < 2e-16 ***
DESTIN_SZWDSZ02      -1.688e-01  6.862e-03   -24.599  < 2e-16 ***
DESTIN_SZWDSZ03       8.356e-01  5.138e-03   162.650  < 2e-16 ***
DESTIN_SZWDSZ04       3.548e-02  7.907e-03     4.487 7.22e-06 ***
DESTIN_SZWDSZ05       1.213e-01  7.573e-03    16.020  < 2e-16 ***
DESTIN_SZWDSZ06       7.008e-01  5.196e-03   134.880  < 2e-16 ***
DESTIN_SZWDSZ07      -8.128e-02  6.776e-03   -11.995  < 2e-16 ***
DESTIN_SZWDSZ08       3.566e-01  6.926e-03    51.492  < 2e-16 ***
DESTIN_SZWDSZ09       1.286e+00  5.047e-03   254.752  < 2e-16 ***
DESTIN_SZYSSZ01       8.410e-01  4.413e-03   190.577  < 2e-16 ***
DESTIN_SZYSSZ02       3.055e-01  5.824e-03    52.464  < 2e-16 ***
DESTIN_SZYSSZ03      -6.562e-02  6.834e-03    -9.602  < 2e-16 ***
DESTIN_SZYSSZ04      -9.208e-02  6.083e-03   -15.137  < 2e-16 ***
DESTIN_SZYSSZ05      -9.496e-01  1.218e-02   -77.946  < 2e-16 ***
DESTIN_SZYSSZ06      -1.434e+00  1.257e-02  -114.040  < 2e-16 ***
DESTIN_SZYSSZ07      -7.694e-01  1.653e-02   -46.549  < 2e-16 ***
DESTIN_SZYSSZ08       9.602e-01  4.589e-03   209.266  < 2e-16 ***
DESTIN_SZYSSZ09       3.229e-01  4.797e-03    67.314  < 2e-16 ***
log(ORIGIN_AGE25_64)  5.796e-02  6.135e-05   944.718  < 2e-16 ***
log(dist)            -1.790e+00  4.774e-04 -3749.675  < 2e-16 ***
---
Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

(Dispersion parameter for poisson family taken to be 1)

    Null deviance: 36117615  on 14273  degrees of freedom
Residual deviance: 13004479  on 13992  degrees of freedom
AIC: 13089597

Number of Fisher Scoring iterations: 7

We can examine how the constraints hold for destinations this time.

CalcRSquared(decSIM$data$TRIPS, decSIM$fitted.values)
[1] 0.4524005

Doubly constrained

In this section, we will fit a doubly constrained SIM by using the code chunk below.

The general formula of Doubly Constrained Spatial Interaction Model

lambda_ij = exp(k + mu_i + alpha_i - Beta ln d_ij)

dbcSIM <- glm(formula = TRIPS ~ 
                ORIGIN_SZ + 
                DESTIN_SZ + 
                log(dist),
              family = poisson(link = "log"),
              data = SIM_data,
              na.action = na.exclude)
summary(dbcSIM)

Call:
glm(formula = TRIPS ~ ORIGIN_SZ + DESTIN_SZ + log(dist), family = poisson(link = "log"), 
    data = SIM_data, na.action = na.exclude)

Coefficients:
                  Estimate Std. Error   z value Pr(>|z|)    
(Intercept)     21.9587595  0.0066831  3285.715  < 2e-16 ***
ORIGIN_SZAMSZ02  0.4778050  0.0054127    88.275  < 2e-16 ***
ORIGIN_SZAMSZ03  0.2895973  0.0055517    52.163  < 2e-16 ***
ORIGIN_SZAMSZ04 -0.2628080  0.0060720   -43.282  < 2e-16 ***
ORIGIN_SZAMSZ05 -0.2631404  0.0069008   -38.132  < 2e-16 ***
ORIGIN_SZAMSZ06  0.1722337  0.0062028    27.767  < 2e-16 ***
ORIGIN_SZAMSZ07 -0.9883200  0.0111224   -88.859  < 2e-16 ***
ORIGIN_SZAMSZ08 -0.4052821  0.0104095   -38.934  < 2e-16 ***
ORIGIN_SZAMSZ09  0.0356290  0.0064816     5.497 3.86e-08 ***
ORIGIN_SZAMSZ10  0.4815569  0.0055521    86.735  < 2e-16 ***
ORIGIN_SZAMSZ11 -1.4440079  0.0146079   -98.851  < 2e-16 ***
ORIGIN_SZAMSZ12 -1.7862677  0.0128071  -139.475  < 2e-16 ***
ORIGIN_SZBDSZ01  0.8653749  0.0054381   159.132  < 2e-16 ***
ORIGIN_SZBDSZ02  0.0841000  0.0062834    13.385  < 2e-16 ***
ORIGIN_SZBDSZ03  0.3158343  0.0057510    54.918  < 2e-16 ***
ORIGIN_SZBDSZ04  1.4556701  0.0049986   291.215  < 2e-16 ***
ORIGIN_SZBDSZ05  0.6363125  0.0057193   111.257  < 2e-16 ***
ORIGIN_SZBDSZ06  0.6749341  0.0058650   115.078  < 2e-16 ***
ORIGIN_SZBDSZ07 -1.2176407  0.0113698  -107.095  < 2e-16 ***
ORIGIN_SZBDSZ08 -0.9803580  0.0105604   -92.833  < 2e-16 ***
ORIGIN_SZBKSZ01 -0.2919642  0.0080763   -36.151  < 2e-16 ***
ORIGIN_SZBKSZ02  0.4609570  0.0067997    67.791  < 2e-16 ***
ORIGIN_SZBKSZ03  0.6273448  0.0065989    95.068  < 2e-16 ***
ORIGIN_SZBKSZ04 -0.2499063  0.0076555   -32.644  < 2e-16 ***
ORIGIN_SZBKSZ05 -0.2628428  0.0078905   -33.311  < 2e-16 ***
ORIGIN_SZBKSZ06 -0.2174034  0.0075134   -28.936  < 2e-16 ***
ORIGIN_SZBKSZ07  0.7094093  0.0058574   121.114  < 2e-16 ***
ORIGIN_SZBKSZ08 -0.1614362  0.0067626   -23.872  < 2e-16 ***
ORIGIN_SZBKSZ09 -0.2739085  0.0072969   -37.537  < 2e-16 ***
ORIGIN_SZBLSZ01 -2.4281074  0.0181172  -134.022  < 2e-16 ***
ORIGIN_SZBLSZ02 -2.7305447  0.0219341  -124.489  < 2e-16 ***
ORIGIN_SZBLSZ03 -3.3071431  0.0540398   -61.198  < 2e-16 ***
ORIGIN_SZBLSZ04 -2.4550671  0.0263946   -93.014  < 2e-16 ***
ORIGIN_SZBMSZ01  0.1198976  0.0065964    18.176  < 2e-16 ***
ORIGIN_SZBMSZ02 -1.3908667  0.0083230  -167.112  < 2e-16 ***
ORIGIN_SZBMSZ03 -0.6999122  0.0069754  -100.339  < 2e-16 ***
ORIGIN_SZBMSZ04 -0.2691159  0.0066184   -40.662  < 2e-16 ***
ORIGIN_SZBMSZ05 -2.6163780  0.0190989  -136.991  < 2e-16 ***
ORIGIN_SZBMSZ06 -2.9729956  0.0197182  -150.774  < 2e-16 ***
ORIGIN_SZBMSZ07 -0.7309916  0.0072407  -100.956  < 2e-16 ***
ORIGIN_SZBMSZ08 -1.0019514  0.0073169  -136.936  < 2e-16 ***
ORIGIN_SZBMSZ09 -1.3667460  0.0105325  -129.764  < 2e-16 ***
ORIGIN_SZBMSZ10 -1.6907268  0.0106687  -158.476  < 2e-16 ***
ORIGIN_SZBMSZ11 -1.2288802  0.0082919  -148.202  < 2e-16 ***
ORIGIN_SZBMSZ12 -1.6517767  0.0115101  -143.507  < 2e-16 ***
ORIGIN_SZBMSZ13 -0.7251351  0.0075289   -96.314  < 2e-16 ***
ORIGIN_SZBMSZ14 -1.1534912  0.0082629  -139.599  < 2e-16 ***
ORIGIN_SZBMSZ15 -0.5476774  0.0075710   -72.339  < 2e-16 ***
ORIGIN_SZBMSZ16 -1.5195034  0.0111459  -136.329  < 2e-16 ***
ORIGIN_SZBMSZ17 -1.6026767  0.0184419   -86.904  < 2e-16 ***
ORIGIN_SZBPSZ01  0.5571291  0.0071866    77.523  < 2e-16 ***
ORIGIN_SZBPSZ02  0.0523197  0.0082259     6.360 2.01e-10 ***
ORIGIN_SZBPSZ03  0.2942047  0.0080482    36.555  < 2e-16 ***
ORIGIN_SZBPSZ04  0.6246296  0.0065878    94.816  < 2e-16 ***
ORIGIN_SZBPSZ05  0.8663708  0.0060852   142.372  < 2e-16 ***
ORIGIN_SZBPSZ06 -0.9896182  0.0109551   -90.334  < 2e-16 ***
ORIGIN_SZBPSZ07 -0.5219250  0.0101830   -51.255  < 2e-16 ***
ORIGIN_SZBSSZ01  0.3299588  0.0066440    49.663  < 2e-16 ***
ORIGIN_SZBSSZ02  0.2851357  0.0057077    49.956  < 2e-16 ***
ORIGIN_SZBSSZ03 -0.2084740  0.0063364   -32.901  < 2e-16 ***
ORIGIN_SZBTSZ01  0.1425664  0.0071103    20.051  < 2e-16 ***
ORIGIN_SZBTSZ02 -0.5591999  0.0093616   -59.733  < 2e-16 ***
ORIGIN_SZBTSZ03 -0.3648190  0.0081677   -44.666  < 2e-16 ***
ORIGIN_SZBTSZ04 -1.4555078  0.0120138  -121.152  < 2e-16 ***
ORIGIN_SZBTSZ05 -0.8635510  0.0133848   -64.517  < 2e-16 ***
ORIGIN_SZBTSZ06 -1.1383111  0.0106421  -106.963  < 2e-16 ***
ORIGIN_SZBTSZ07 -2.3477669  0.0160858  -145.953  < 2e-16 ***
ORIGIN_SZBTSZ08 -1.2918779  0.0124862  -103.464  < 2e-16 ***
ORIGIN_SZCBSZ01 -3.3713588  0.0578683   -58.259  < 2e-16 ***
ORIGIN_SZCCSZ01 -0.6029242  0.0153385   -39.308  < 2e-16 ***
ORIGIN_SZCHSZ01 -0.7641380  0.0135100   -56.561  < 2e-16 ***
ORIGIN_SZCHSZ02 -0.8400736  0.0101951   -82.400  < 2e-16 ***
ORIGIN_SZCHSZ03  1.2753127  0.0072576   175.720  < 2e-16 ***
ORIGIN_SZCKSZ01  0.2470943  0.0067135    36.806  < 2e-16 ***
ORIGIN_SZCKSZ02  0.5793581  0.0070498    82.181  < 2e-16 ***
ORIGIN_SZCKSZ03  1.0795767  0.0060642   178.025  < 2e-16 ***
ORIGIN_SZCKSZ04  1.4947920  0.0063122   236.808  < 2e-16 ***
ORIGIN_SZCKSZ05  0.7457580  0.0074071   100.681  < 2e-16 ***
ORIGIN_SZCKSZ06  0.5760952  0.0094861    60.730  < 2e-16 ***
ORIGIN_SZCLSZ01 -0.9061335  0.0098617   -91.884  < 2e-16 ***
ORIGIN_SZCLSZ02 -1.7609479  0.0156124  -112.791  < 2e-16 ***
ORIGIN_SZCLSZ03 -1.0081325  0.0095171  -105.929  < 2e-16 ***
ORIGIN_SZCLSZ04  0.6181200  0.0057953   106.659  < 2e-16 ***
ORIGIN_SZCLSZ05 -2.0462335  0.0168934  -121.127  < 2e-16 ***
ORIGIN_SZCLSZ06  0.7902389  0.0055680   141.924  < 2e-16 ***
ORIGIN_SZCLSZ07 -0.5472929  0.0071001   -77.082  < 2e-16 ***
ORIGIN_SZCLSZ08 -0.2197650  0.0077460   -28.372  < 2e-16 ***
ORIGIN_SZCLSZ09 -1.8175782  0.0195989   -92.739  < 2e-16 ***
ORIGIN_SZDTSZ02 -3.7618796  0.0872098   -43.136  < 2e-16 ***
ORIGIN_SZDTSZ03 -3.4514766  0.0840812   -41.049  < 2e-16 ***
ORIGIN_SZDTSZ13 -3.0627578  0.0352485   -86.891  < 2e-16 ***
ORIGIN_SZGLSZ01 -1.8055929  0.0111938  -161.303  < 2e-16 ***
ORIGIN_SZGLSZ02 -0.1588829  0.0061413   -25.871  < 2e-16 ***
ORIGIN_SZGLSZ03 -0.2508524  0.0064276   -39.027  < 2e-16 ***
ORIGIN_SZGLSZ04  0.8819358  0.0051993   169.627  < 2e-16 ***
ORIGIN_SZGLSZ05  0.6062778  0.0053735   112.828  < 2e-16 ***
ORIGIN_SZHGSZ01  0.3841503  0.0056776    67.660  < 2e-16 ***
ORIGIN_SZHGSZ02  0.3962330  0.0057579    68.815  < 2e-16 ***
ORIGIN_SZHGSZ03  0.2159531  0.0061671    35.017  < 2e-16 ***
ORIGIN_SZHGSZ04  0.7831941  0.0052216   149.992  < 2e-16 ***
ORIGIN_SZHGSZ05  1.1741558  0.0051799   226.677  < 2e-16 ***
ORIGIN_SZHGSZ06 -0.1891403  0.0065556   -28.852  < 2e-16 ***
ORIGIN_SZHGSZ07  0.3105421  0.0057186    54.304  < 2e-16 ***
ORIGIN_SZHGSZ08 -0.0766364  0.0063474   -12.074  < 2e-16 ***
ORIGIN_SZHGSZ09 -1.2211107  0.0101434  -120.384  < 2e-16 ***
ORIGIN_SZHGSZ10 -3.4844709  0.0504793   -69.028  < 2e-16 ***
ORIGIN_SZJESZ01  0.4916496  0.0063444    77.493  < 2e-16 ***
ORIGIN_SZJESZ02  0.1343893  0.0063762    21.077  < 2e-16 ***
ORIGIN_SZJESZ03 -0.2761723  0.0068085   -40.563  < 2e-16 ***
ORIGIN_SZJESZ04 -1.5932744  0.0121402  -131.240  < 2e-16 ***
ORIGIN_SZJESZ05 -2.3041311  0.0160245  -143.788  < 2e-16 ***
ORIGIN_SZJESZ06  0.2811076  0.0062495    44.981  < 2e-16 ***
ORIGIN_SZJESZ07 -1.9413956  0.0136276  -142.461  < 2e-16 ***
ORIGIN_SZJESZ08 -1.3315645  0.0143168   -93.007  < 2e-16 ***
ORIGIN_SZJESZ09  0.4418314  0.0069208    63.841  < 2e-16 ***
ORIGIN_SZJESZ10 -1.5551555  0.0236523   -65.751  < 2e-16 ***
ORIGIN_SZJESZ11 -1.8888230  0.0224630   -84.086  < 2e-16 ***
ORIGIN_SZJWSZ01  0.2564586  0.0084699    30.279  < 2e-16 ***
ORIGIN_SZJWSZ02  0.6899398  0.0061751   111.729  < 2e-16 ***
ORIGIN_SZJWSZ03  1.4761229  0.0057392   257.198  < 2e-16 ***
ORIGIN_SZJWSZ04  0.5701272  0.0065749    86.713  < 2e-16 ***
ORIGIN_SZJWSZ05 -2.1253657  0.0150769  -140.968  < 2e-16 ***
ORIGIN_SZJWSZ06 -1.5307265  0.0131906  -116.047  < 2e-16 ***
ORIGIN_SZJWSZ07 -2.8801618  0.0360772   -79.833  < 2e-16 ***
ORIGIN_SZJWSZ08  1.4428820  0.0059638   241.938  < 2e-16 ***
ORIGIN_SZJWSZ09  1.8968475  0.0055649   340.860  < 2e-16 ***
ORIGIN_SZKLSZ01  0.1116580  0.0059844    18.658  < 2e-16 ***
ORIGIN_SZKLSZ02 -0.9618787  0.0077344  -124.364  < 2e-16 ***
ORIGIN_SZKLSZ03 -0.7070626  0.0070275  -100.613  < 2e-16 ***
ORIGIN_SZKLSZ04 -2.2742765  0.0139991  -162.459  < 2e-16 ***
ORIGIN_SZKLSZ05 -1.1907262  0.0123719   -96.244  < 2e-16 ***
ORIGIN_SZKLSZ06 -5.9774897  0.1857994   -32.172  < 2e-16 ***
ORIGIN_SZKLSZ07 -1.4258369  0.0103083  -138.320  < 2e-16 ***
ORIGIN_SZKLSZ08 -1.7625888  0.0116107  -151.808  < 2e-16 ***
ORIGIN_SZLKSZ01 -2.0541388  0.0448216   -45.829  < 2e-16 ***
ORIGIN_SZMDSZ01 -0.8571117  0.0321054   -26.697  < 2e-16 ***
ORIGIN_SZMDSZ02 -0.6034597  0.0120724   -49.987  < 2e-16 ***
ORIGIN_SZMDSZ03 -2.1681163  0.0201078  -107.825  < 2e-16 ***
ORIGIN_SZMPSZ01 -0.9331562  0.0096218   -96.984  < 2e-16 ***
ORIGIN_SZMPSZ02 -1.0268229  0.0081379  -126.178  < 2e-16 ***
ORIGIN_SZMPSZ03  0.0054001  0.0066875     0.807 0.419385    
ORIGIN_SZMUSZ02 -3.6269863  0.1105492   -32.809  < 2e-16 ***
ORIGIN_SZNTSZ01 -3.0593717  0.0399843   -76.514  < 2e-16 ***
ORIGIN_SZNTSZ02 -3.3331415  0.0251754  -132.397  < 2e-16 ***
ORIGIN_SZNTSZ03 -0.8351522  0.0090372   -92.413  < 2e-16 ***
ORIGIN_SZNTSZ05 -4.2082472  0.0583343   -72.140  < 2e-16 ***
ORIGIN_SZNTSZ06 -3.8549296  0.0593793   -64.920  < 2e-16 ***
ORIGIN_SZNVSZ01  0.2789069  0.0056024    49.784  < 2e-16 ***
ORIGIN_SZNVSZ02 -0.6036857  0.0077126   -78.273  < 2e-16 ***
ORIGIN_SZNVSZ03 -1.0072683  0.0092678  -108.685  < 2e-16 ***
ORIGIN_SZNVSZ04 -0.8723996  0.0101399   -86.037  < 2e-16 ***
ORIGIN_SZNVSZ05 -2.1552928  0.0183064  -117.734  < 2e-16 ***
ORIGIN_SZPGSZ01  0.0520607  0.0157846     3.298 0.000973 ***
ORIGIN_SZPGSZ02 -0.3481687  0.0089328   -38.976  < 2e-16 ***
ORIGIN_SZPGSZ03  0.9095292  0.0058835   154.590  < 2e-16 ***
ORIGIN_SZPGSZ04  1.3653717  0.0054727   249.489  < 2e-16 ***
ORIGIN_SZPGSZ05  0.3762720  0.0073841    50.957  < 2e-16 ***
ORIGIN_SZPLSZ01 -0.9142754  0.0136552   -66.954  < 2e-16 ***
ORIGIN_SZPLSZ02 -1.0987582  0.0175891   -62.468  < 2e-16 ***
ORIGIN_SZPLSZ03 -2.3427113  0.0474176   -49.406  < 2e-16 ***
ORIGIN_SZPLSZ04 -2.9140779  0.0374458   -77.821  < 2e-16 ***
ORIGIN_SZPLSZ05 -2.2381965  0.0261572   -85.567  < 2e-16 ***
ORIGIN_SZPNSZ01  0.9659006  0.0075177   128.484  < 2e-16 ***
ORIGIN_SZPNSZ02 -0.0158348  0.0143869    -1.101 0.271053    
ORIGIN_SZPNSZ03 -2.1837321  0.0224396   -97.316  < 2e-16 ***
ORIGIN_SZPNSZ04 -3.2481509  0.0370762   -87.608  < 2e-16 ***
ORIGIN_SZPNSZ05 -2.0450679  0.0328165   -62.318  < 2e-16 ***
ORIGIN_SZPRSZ01 -0.6701245  0.0141567   -47.336  < 2e-16 ***
ORIGIN_SZPRSZ02  0.7931907  0.0058079   136.570  < 2e-16 ***
ORIGIN_SZPRSZ03  0.4249094  0.0058610    72.498  < 2e-16 ***
ORIGIN_SZPRSZ04 -0.8529967  0.0090997   -93.739  < 2e-16 ***
ORIGIN_SZPRSZ05  0.7865479  0.0055282   142.278  < 2e-16 ***
ORIGIN_SZPRSZ06 -1.3303664  0.0134512   -98.903  < 2e-16 ***
ORIGIN_SZPRSZ07 -3.0458370  0.0181514  -167.802  < 2e-16 ***
ORIGIN_SZPRSZ08 -0.5342399  0.0075966   -70.327  < 2e-16 ***
ORIGIN_SZQTSZ01 -0.2548930  0.0086485   -29.473  < 2e-16 ***
ORIGIN_SZQTSZ02 -0.8662439  0.0076549  -113.162  < 2e-16 ***
ORIGIN_SZQTSZ03 -0.0890168  0.0072455   -12.286  < 2e-16 ***
ORIGIN_SZQTSZ04 -1.4634370  0.0089384  -163.724  < 2e-16 ***
ORIGIN_SZQTSZ05 -0.6535669  0.0077612   -84.210  < 2e-16 ***
ORIGIN_SZQTSZ06 -0.8275765  0.0081835  -101.128  < 2e-16 ***
ORIGIN_SZQTSZ07 -1.5369800  0.0112808  -136.248  < 2e-16 ***
ORIGIN_SZQTSZ08 -0.4437979  0.0075302   -58.936  < 2e-16 ***
ORIGIN_SZQTSZ09 -0.8184934  0.0083589   -97.918  < 2e-16 ***
ORIGIN_SZQTSZ10 -0.6906597  0.0080980   -85.288  < 2e-16 ***
ORIGIN_SZQTSZ11 -2.3251162  0.0154191  -150.795  < 2e-16 ***
ORIGIN_SZQTSZ12 -3.0442790  0.0208985  -145.670  < 2e-16 ***
ORIGIN_SZQTSZ13 -0.7241013  0.0093441   -77.493  < 2e-16 ***
ORIGIN_SZQTSZ14 -1.8225351  0.0138207  -131.870  < 2e-16 ***
ORIGIN_SZQTSZ15 -0.8720806  0.0138589   -62.926  < 2e-16 ***
ORIGIN_SZRCSZ01 -1.8063415  0.0144295  -125.184  < 2e-16 ***
ORIGIN_SZRCSZ06 -0.5370905  0.0101573   -52.877  < 2e-16 ***
ORIGIN_SZRVSZ01 -2.7426167  0.0341386   -80.338  < 2e-16 ***
ORIGIN_SZRVSZ02 -3.0827269  0.0302299  -101.976  < 2e-16 ***
ORIGIN_SZRVSZ03 -2.9133853  0.0262543  -110.968  < 2e-16 ***
ORIGIN_SZRVSZ04 -3.4220022  0.0582209   -58.776  < 2e-16 ***
ORIGIN_SZRVSZ05 -2.6206257  0.0197470  -132.710  < 2e-16 ***
ORIGIN_SZSBSZ01  0.1010337  0.0085117    11.870  < 2e-16 ***
ORIGIN_SZSBSZ02 -0.8810456  0.0098244   -89.680  < 2e-16 ***
ORIGIN_SZSBSZ03  0.8303668  0.0063009   131.785  < 2e-16 ***
ORIGIN_SZSBSZ04  0.3489128  0.0071456    48.829  < 2e-16 ***
ORIGIN_SZSBSZ05 -0.3182914  0.0085560   -37.201  < 2e-16 ***
ORIGIN_SZSBSZ06 -0.9074308  0.0200035   -45.364  < 2e-16 ***
ORIGIN_SZSBSZ07 -0.2217124  0.0167188   -13.261  < 2e-16 ***
ORIGIN_SZSBSZ08 -1.3007367  0.0178771   -72.760  < 2e-16 ***
ORIGIN_SZSBSZ09 -0.9813703  0.0107885   -90.965  < 2e-16 ***
ORIGIN_SZSESZ02  1.1283424  0.0054209   208.146  < 2e-16 ***
ORIGIN_SZSESZ03  1.2389996  0.0051926   238.610  < 2e-16 ***
ORIGIN_SZSESZ04  0.7535119  0.0060371   124.814  < 2e-16 ***
ORIGIN_SZSESZ05 -0.2347978  0.0071482   -32.847  < 2e-16 ***
ORIGIN_SZSESZ06  0.9520620  0.0057572   165.368  < 2e-16 ***
ORIGIN_SZSESZ07 -2.4296685  0.0231677  -104.873  < 2e-16 ***
ORIGIN_SZSGSZ01 -0.6995899  0.0099969   -69.980  < 2e-16 ***
ORIGIN_SZSGSZ02 -1.2602157  0.0111471  -113.053  < 2e-16 ***
ORIGIN_SZSGSZ03  0.0725860  0.0061970    11.713  < 2e-16 ***
ORIGIN_SZSGSZ04  0.2738315  0.0057524    47.603  < 2e-16 ***
ORIGIN_SZSGSZ05 -2.0207710  0.0119838  -168.625  < 2e-16 ***
ORIGIN_SZSGSZ06  0.4885608  0.0054646    89.404  < 2e-16 ***
ORIGIN_SZSGSZ07 -0.8892155  0.0075074  -118.445  < 2e-16 ***
ORIGIN_SZSKSZ01 -0.3682754  0.0108025   -34.092  < 2e-16 ***
ORIGIN_SZSKSZ02  1.1826086  0.0071388   165.659  < 2e-16 ***
ORIGIN_SZSKSZ03 -0.3230177  0.0101683   -31.767  < 2e-16 ***
ORIGIN_SZSKSZ04 -1.8504236  0.0362400   -51.060  < 2e-16 ***
ORIGIN_SZSKSZ05 -0.2759035  0.0185157   -14.901  < 2e-16 ***
ORIGIN_SZSLSZ01 -2.2757902  0.0348766   -65.253  < 2e-16 ***
ORIGIN_SZSLSZ04 -0.0899820  0.0090356    -9.959  < 2e-16 ***
ORIGIN_SZSRSZ01 -2.1460151  0.0187871  -114.228  < 2e-16 ***
ORIGIN_SZTHSZ01 -2.6851549  0.0571841   -46.956  < 2e-16 ***
ORIGIN_SZTHSZ03 -1.0121495  0.0275551   -36.732  < 2e-16 ***
ORIGIN_SZTHSZ04 -2.6129645  0.0345167   -75.701  < 2e-16 ***
ORIGIN_SZTHSZ06 -1.7229100  0.0208134   -82.779  < 2e-16 ***
ORIGIN_SZTMSZ01 -0.2254986  0.0070312   -32.071  < 2e-16 ***
ORIGIN_SZTMSZ02  1.7271575  0.0049219   350.914  < 2e-16 ***
ORIGIN_SZTMSZ03  0.9891319  0.0052266   189.250  < 2e-16 ***
ORIGIN_SZTMSZ04  0.2018090  0.0062114    32.490  < 2e-16 ***
ORIGIN_SZTMSZ05 -1.1882870  0.0125842   -94.427  < 2e-16 ***
ORIGIN_SZTNSZ01 -1.6122620  0.0141911  -113.611  < 2e-16 ***
ORIGIN_SZTNSZ02 -1.5630967  0.0112227  -139.280  < 2e-16 ***
ORIGIN_SZTNSZ03 -2.0739538  0.0149298  -138.914  < 2e-16 ***
ORIGIN_SZTNSZ04 -0.2816960  0.0085295   -33.026  < 2e-16 ***
ORIGIN_SZTPSZ01 -0.7822239  0.0077901  -100.412  < 2e-16 ***
ORIGIN_SZTPSZ02  0.5735478  0.0053042   108.131  < 2e-16 ***
ORIGIN_SZTPSZ03 -0.8748650  0.0074202  -117.903  < 2e-16 ***
ORIGIN_SZTPSZ04 -0.8537831  0.0069792  -122.332  < 2e-16 ***
ORIGIN_SZTPSZ05 -0.5581114  0.0077012   -72.471  < 2e-16 ***
ORIGIN_SZTPSZ06  0.0262001  0.0075241     3.482 0.000497 ***
ORIGIN_SZTPSZ07 -0.5969952  0.0074272   -80.380  < 2e-16 ***
ORIGIN_SZTPSZ08 -1.0537959  0.0111297   -94.683  < 2e-16 ***
ORIGIN_SZTPSZ09 -0.9588508  0.0081314  -117.920  < 2e-16 ***
ORIGIN_SZTPSZ10 -1.1177249  0.0089403  -125.021  < 2e-16 ***
ORIGIN_SZTPSZ11 -0.2799677  0.0067135   -41.702  < 2e-16 ***
ORIGIN_SZTPSZ12 -0.8898871  0.0080215  -110.938  < 2e-16 ***
ORIGIN_SZTSSZ01 -2.6146463  0.0521606   -50.127  < 2e-16 ***
ORIGIN_SZTSSZ02  0.1682588  0.0119965    14.026  < 2e-16 ***
ORIGIN_SZTSSZ03  0.2587653  0.0123809    20.900  < 2e-16 ***
ORIGIN_SZTSSZ04 -0.5473825  0.0135215   -40.482  < 2e-16 ***
ORIGIN_SZTSSZ05 -0.9967379  0.0206068   -48.369  < 2e-16 ***
ORIGIN_SZTSSZ06  0.4933147  0.0229597    21.486  < 2e-16 ***
ORIGIN_SZWCSZ01  1.2524706  0.0111133   112.700  < 2e-16 ***
ORIGIN_SZWCSZ02 -2.8544820  0.0347805   -82.071  < 2e-16 ***
ORIGIN_SZWCSZ03 -5.1277334  0.1475585   -34.751  < 2e-16 ***
ORIGIN_SZWDSZ01  1.4725308  0.0056496   260.645  < 2e-16 ***
ORIGIN_SZWDSZ02  0.1571680  0.0064909    24.214  < 2e-16 ***
ORIGIN_SZWDSZ03  1.2584097  0.0061471   204.717  < 2e-16 ***
ORIGIN_SZWDSZ04  0.8578765  0.0069277   123.833  < 2e-16 ***
ORIGIN_SZWDSZ05  0.1702728  0.0069687    24.434  < 2e-16 ***
ORIGIN_SZWDSZ06  0.1736910  0.0069507    24.989  < 2e-16 ***
ORIGIN_SZWDSZ07 -1.5610176  0.0100803  -154.859  < 2e-16 ***
ORIGIN_SZWDSZ08 -0.9490906  0.0102047   -93.005  < 2e-16 ***
ORIGIN_SZWDSZ09  1.2107011  0.0062294   194.354  < 2e-16 ***
ORIGIN_SZYSSZ01 -0.3324158  0.0074537   -44.598  < 2e-16 ***
ORIGIN_SZYSSZ02  0.8177113  0.0066108   123.693  < 2e-16 ***
ORIGIN_SZYSSZ03  1.6751777  0.0058470   286.503  < 2e-16 ***
ORIGIN_SZYSSZ04  0.8130044  0.0059025   137.738  < 2e-16 ***
ORIGIN_SZYSSZ05  0.3678420  0.0072431    50.785  < 2e-16 ***
ORIGIN_SZYSSZ06 -0.6024384  0.0126722   -47.540  < 2e-16 ***
ORIGIN_SZYSSZ07 -0.7631918  0.0158478   -48.157  < 2e-16 ***
ORIGIN_SZYSSZ08  0.2141930  0.0076154    28.126  < 2e-16 ***
ORIGIN_SZYSSZ09  1.0809368  0.0057973   186.457  < 2e-16 ***
DESTIN_SZAMSZ02  0.0761304  0.0051207    14.867  < 2e-16 ***
DESTIN_SZAMSZ03  0.0143394  0.0050755     2.825 0.004724 ** 
DESTIN_SZAMSZ04 -1.2516780  0.0074947  -167.008  < 2e-16 ***
DESTIN_SZAMSZ05 -1.2312375  0.0076598  -160.741  < 2e-16 ***
DESTIN_SZAMSZ06 -1.0333412  0.0075283  -137.261  < 2e-16 ***
DESTIN_SZAMSZ07 -1.5338249  0.0110036  -139.392  < 2e-16 ***
DESTIN_SZAMSZ08 -0.3751665  0.0075358   -49.784  < 2e-16 ***
DESTIN_SZAMSZ09 -1.1633493  0.0077556  -150.001  < 2e-16 ***
DESTIN_SZAMSZ10  0.1017717  0.0053151    19.148  < 2e-16 ***
DESTIN_SZAMSZ11 -0.8840362  0.0097007   -91.131  < 2e-16 ***
DESTIN_SZAMSZ12  0.1628123  0.0055220    29.484  < 2e-16 ***
DESTIN_SZBDSZ01  1.0040794  0.0047922   209.523  < 2e-16 ***
DESTIN_SZBDSZ02 -0.2478149  0.0063085   -39.283  < 2e-16 ***
DESTIN_SZBDSZ03  0.1016088  0.0057420    17.696  < 2e-16 ***
DESTIN_SZBDSZ04  1.1082928  0.0047747   232.116  < 2e-16 ***
DESTIN_SZBDSZ05  0.8737933  0.0050593   172.712  < 2e-16 ***
DESTIN_SZBDSZ06  0.2897032  0.0058244    49.740  < 2e-16 ***
DESTIN_SZBDSZ07 -0.9026193  0.0113656   -79.416  < 2e-16 ***
DESTIN_SZBDSZ08 -1.7063577  0.0131234  -130.024  < 2e-16 ***
DESTIN_SZBKSZ01 -1.3892839  0.0083307  -166.767  < 2e-16 ***
DESTIN_SZBKSZ02 -0.6661120  0.0073464   -90.672  < 2e-16 ***
DESTIN_SZBKSZ03 -0.9536826  0.0073196  -130.292  < 2e-16 ***
DESTIN_SZBKSZ04 -0.6655610  0.0065868  -101.044  < 2e-16 ***
DESTIN_SZBKSZ05 -0.9053119  0.0079264  -114.215  < 2e-16 ***
DESTIN_SZBKSZ06 -1.2622159  0.0075079  -168.119  < 2e-16 ***
DESTIN_SZBKSZ07 -0.0423370  0.0056686    -7.469 8.10e-14 ***
DESTIN_SZBKSZ08 -1.3811240  0.0084985  -162.515  < 2e-16 ***
DESTIN_SZBKSZ09 -0.0797012  0.0061428   -12.975  < 2e-16 ***
DESTIN_SZBLSZ01 -0.8859670  0.0088108  -100.555  < 2e-16 ***
DESTIN_SZBLSZ02  0.1362723  0.0082167    16.585  < 2e-16 ***
DESTIN_SZBLSZ03  1.2037396  0.0093508   128.732  < 2e-16 ***
DESTIN_SZBLSZ04 -0.9316219  0.0178080   -52.315  < 2e-16 ***
DESTIN_SZBMSZ01  0.7188470  0.0061160   117.536  < 2e-16 ***
DESTIN_SZBMSZ02 -0.0597895  0.0061206    -9.769  < 2e-16 ***
DESTIN_SZBMSZ03 -0.2427075  0.0069937   -34.704  < 2e-16 ***
DESTIN_SZBMSZ04 -0.0622494  0.0065569    -9.494  < 2e-16 ***
DESTIN_SZBMSZ05 -0.2857019  0.0086450   -33.048  < 2e-16 ***
DESTIN_SZBMSZ06 -1.3486558  0.0158904   -84.872  < 2e-16 ***
DESTIN_SZBMSZ07  0.4549687  0.0058315    78.020  < 2e-16 ***
DESTIN_SZBMSZ08 -0.8730268  0.0077814  -112.195  < 2e-16 ***
DESTIN_SZBMSZ09 -2.0319890  0.0163038  -124.633  < 2e-16 ***
DESTIN_SZBMSZ10 -1.4319101  0.0102616  -139.541  < 2e-16 ***
DESTIN_SZBMSZ11 -1.2429176  0.0092250  -134.733  < 2e-16 ***
DESTIN_SZBMSZ12 -0.8526549  0.0096009   -88.810  < 2e-16 ***
DESTIN_SZBMSZ13  0.1399907  0.0066885    20.930  < 2e-16 ***
DESTIN_SZBMSZ14 -1.0103155  0.0091377  -110.566  < 2e-16 ***
DESTIN_SZBMSZ15 -0.6819769  0.0086179   -79.135  < 2e-16 ***
DESTIN_SZBMSZ16 -1.4468308  0.0134051  -107.931  < 2e-16 ***
DESTIN_SZBMSZ17 -1.5312175  0.0186843   -81.952  < 2e-16 ***
DESTIN_SZBPSZ01 -1.1726725  0.0073257  -160.077  < 2e-16 ***
DESTIN_SZBPSZ02 -2.1072012  0.0103320  -203.949  < 2e-16 ***
DESTIN_SZBPSZ03 -1.6944911  0.0098520  -171.995  < 2e-16 ***
DESTIN_SZBPSZ04 -0.7664610  0.0074458  -102.939  < 2e-16 ***
DESTIN_SZBPSZ05  0.1358370  0.0056258    24.145  < 2e-16 ***
DESTIN_SZBPSZ06 -1.2425471  0.0096942  -128.175  < 2e-16 ***
DESTIN_SZBPSZ07 -0.1666192  0.0094969   -17.545  < 2e-16 ***
DESTIN_SZBSSZ01  0.3857894  0.0057261    67.374  < 2e-16 ***
DESTIN_SZBSSZ02 -0.5293265  0.0064886   -81.578  < 2e-16 ***
DESTIN_SZBSSZ03  0.3909966  0.0048540    80.551  < 2e-16 ***
DESTIN_SZBTSZ01  0.7114965  0.0054528   130.482  < 2e-16 ***
DESTIN_SZBTSZ02 -0.0487084  0.0082474    -5.906 3.51e-09 ***
DESTIN_SZBTSZ03  0.5539032  0.0064423    85.979  < 2e-16 ***
DESTIN_SZBTSZ04 -0.7120734  0.0128676   -55.339  < 2e-16 ***
DESTIN_SZBTSZ05  0.2176097  0.0086791    25.073  < 2e-16 ***
DESTIN_SZBTSZ06 -0.2167084  0.0084925   -25.518  < 2e-16 ***
DESTIN_SZBTSZ07 -1.4045618  0.0124363  -112.940  < 2e-16 ***
DESTIN_SZBTSZ08 -0.8213918  0.0120793   -68.000  < 2e-16 ***
DESTIN_SZCBSZ01 -5.7340877  0.3333916   -17.199  < 2e-16 ***
DESTIN_SZCCSZ01 -0.0304192  0.0095920    -3.171 0.001518 ** 
DESTIN_SZCHSZ01 -0.2598507  0.0115311   -22.535  < 2e-16 ***
DESTIN_SZCHSZ02  0.3497750  0.0068334    51.186  < 2e-16 ***
DESTIN_SZCHSZ03  2.4550172  0.0050883   482.481  < 2e-16 ***
DESTIN_SZCKSZ01 -0.4691744  0.0063130   -74.319  < 2e-16 ***
DESTIN_SZCKSZ02 -0.9557084  0.0069331  -137.847  < 2e-16 ***
DESTIN_SZCKSZ03  0.0442112  0.0057117     7.740 9.91e-15 ***
DESTIN_SZCKSZ04 -0.8592063  0.0081238  -105.764  < 2e-16 ***
DESTIN_SZCKSZ05 -1.1745333  0.0087305  -134.532  < 2e-16 ***
DESTIN_SZCKSZ06 -0.4982877  0.0085514   -58.269  < 2e-16 ***
DESTIN_SZCLSZ01  0.2665065  0.0059712    44.632  < 2e-16 ***
DESTIN_SZCLSZ02 -1.9758876  0.0150823  -131.007  < 2e-16 ***
DESTIN_SZCLSZ03 -0.9051310  0.0091479   -98.944  < 2e-16 ***
DESTIN_SZCLSZ04 -0.0828732  0.0061559   -13.462  < 2e-16 ***
DESTIN_SZCLSZ05 -1.1414780  0.0100760  -113.287  < 2e-16 ***
DESTIN_SZCLSZ06  0.3229402  0.0056269    57.392  < 2e-16 ***
DESTIN_SZCLSZ07 -0.4833612  0.0069777   -69.272  < 2e-16 ***
DESTIN_SZCLSZ08 -0.3219670  0.0075615   -42.580  < 2e-16 ***
DESTIN_SZCLSZ09  0.0564166  0.0080703     6.991 2.74e-12 ***
DESTIN_SZDTSZ02 -1.6384236  0.0374725   -43.723  < 2e-16 ***
DESTIN_SZDTSZ03 -0.4021571  0.0152716   -26.334  < 2e-16 ***
DESTIN_SZDTSZ13 -1.2799441  0.0177095   -72.274  < 2e-16 ***
DESTIN_SZGLSZ01 -0.0190303  0.0060665    -3.137 0.001707 ** 
DESTIN_SZGLSZ02 -0.0308469  0.0058724    -5.253 1.50e-07 ***
DESTIN_SZGLSZ03  0.6927638  0.0048456   142.969  < 2e-16 ***
DESTIN_SZGLSZ04  0.9325848  0.0049183   189.616  < 2e-16 ***
DESTIN_SZGLSZ05  0.8480056  0.0048801   173.768  < 2e-16 ***
DESTIN_SZHGSZ01  0.0652969  0.0047795    13.662  < 2e-16 ***
DESTIN_SZHGSZ02 -0.9498251  0.0066577  -142.667  < 2e-16 ***
DESTIN_SZHGSZ03 -1.4372499  0.0076387  -188.154  < 2e-16 ***
DESTIN_SZHGSZ04 -0.5236292  0.0055353   -94.599  < 2e-16 ***
DESTIN_SZHGSZ05 -0.5420295  0.0058099   -93.295  < 2e-16 ***
DESTIN_SZHGSZ06 -0.9054730  0.0067581  -133.983  < 2e-16 ***
DESTIN_SZHGSZ07  0.0215109  0.0054019     3.982 6.83e-05 ***
DESTIN_SZHGSZ08 -0.0490979  0.0059206    -8.293  < 2e-16 ***
DESTIN_SZHGSZ09 -0.0711560  0.0062875   -11.317  < 2e-16 ***
DESTIN_SZHGSZ10 -3.5807154  0.0290642  -123.200  < 2e-16 ***
DESTIN_SZJESZ01 -0.4023638  0.0065057   -61.848  < 2e-16 ***
DESTIN_SZJESZ02 -0.7654353  0.0067096  -114.081  < 2e-16 ***
DESTIN_SZJESZ03 -0.8778812  0.0071238  -123.232  < 2e-16 ***
DESTIN_SZJESZ04 -1.1998075  0.0088733  -135.215  < 2e-16 ***
DESTIN_SZJESZ05 -1.5623652  0.0116898  -133.652  < 2e-16 ***
DESTIN_SZJESZ06  0.2311474  0.0055595    41.577  < 2e-16 ***
DESTIN_SZJESZ07 -1.2753348  0.0094838  -134.475  < 2e-16 ***
DESTIN_SZJESZ08 -0.7654533  0.0099306   -77.081  < 2e-16 ***
DESTIN_SZJESZ09  0.1637628  0.0074164    22.081  < 2e-16 ***
DESTIN_SZJESZ10  0.7394958  0.0091249    81.041  < 2e-16 ***
DESTIN_SZJESZ11  0.5157364  0.0086546    59.591  < 2e-16 ***
DESTIN_SZJWSZ01 -1.0165204  0.0083025  -122.435  < 2e-16 ***
DESTIN_SZJWSZ02 -0.8530646  0.0067851  -125.727  < 2e-16 ***
DESTIN_SZJWSZ03  0.5176135  0.0056449    91.695  < 2e-16 ***
DESTIN_SZJWSZ04  0.3427105  0.0058499    58.584  < 2e-16 ***
DESTIN_SZJWSZ05 -1.1695940  0.0080069  -146.073  < 2e-16 ***
DESTIN_SZJWSZ06 -0.7466462  0.0070240  -106.299  < 2e-16 ***
DESTIN_SZJWSZ07 -3.0124535  0.0333481   -90.334  < 2e-16 ***
DESTIN_SZJWSZ08 -0.4253502  0.0066584   -63.881  < 2e-16 ***
DESTIN_SZJWSZ09  0.9428005  0.0053190   177.251  < 2e-16 ***
DESTIN_SZKLSZ01 -0.2965013  0.0066422   -44.639  < 2e-16 ***
DESTIN_SZKLSZ02 -0.4921137  0.0067689   -72.702  < 2e-16 ***
DESTIN_SZKLSZ03 -0.8489213  0.0078294  -108.427  < 2e-16 ***
DESTIN_SZKLSZ04 -1.2656342  0.0099918  -126.667  < 2e-16 ***
DESTIN_SZKLSZ05 -0.3570126  0.0096300   -37.073  < 2e-16 ***
DESTIN_SZKLSZ06 -2.4764906  0.0390868   -63.359  < 2e-16 ***
DESTIN_SZKLSZ07 -0.7316189  0.0080994   -90.330  < 2e-16 ***
DESTIN_SZKLSZ08 -0.1115398  0.0061168   -18.235  < 2e-16 ***
DESTIN_SZLKSZ01 -1.4940710  0.0271518   -55.027  < 2e-16 ***
DESTIN_SZMDSZ01 -1.6101440  0.0231238   -69.631  < 2e-16 ***
DESTIN_SZMDSZ02 -0.9339318  0.0126277   -73.959  < 2e-16 ***
DESTIN_SZMDSZ03 -3.4868547  0.0303657  -114.829  < 2e-16 ***
DESTIN_SZMPSZ01 -0.4518483  0.0089869   -50.279  < 2e-16 ***
DESTIN_SZMPSZ02 -0.5868264  0.0073193   -80.176  < 2e-16 ***
DESTIN_SZMPSZ03  0.4805365  0.0059041    81.391  < 2e-16 ***
DESTIN_SZMUSZ02 -1.3837581  0.0218713   -63.268  < 2e-16 ***
DESTIN_SZNTSZ01 -3.0694691  0.0533346   -57.551  < 2e-16 ***
DESTIN_SZNTSZ02 -1.4992973  0.0130358  -115.014  < 2e-16 ***
DESTIN_SZNTSZ03 -0.5221236  0.0089923   -58.064  < 2e-16 ***
DESTIN_SZNTSZ05 -1.9751162  0.0282369   -69.948  < 2e-16 ***
DESTIN_SZNTSZ06 -3.9959411  0.0511214   -78.166  < 2e-16 ***
DESTIN_SZNVSZ01 -0.1126966  0.0057077   -19.745  < 2e-16 ***
DESTIN_SZNVSZ02 -0.0259250  0.0064427    -4.024 5.72e-05 ***
DESTIN_SZNVSZ03 -0.0123214  0.0067692    -1.820 0.068725 .  
DESTIN_SZNVSZ04 -1.3371298  0.0130261  -102.650  < 2e-16 ***
DESTIN_SZNVSZ05 -0.9686333  0.0101539   -95.395  < 2e-16 ***
DESTIN_SZPGSZ01 -1.1798309  0.0180543   -65.349  < 2e-16 ***
DESTIN_SZPGSZ02 -1.3289737  0.0085335  -155.736  < 2e-16 ***
DESTIN_SZPGSZ03 -0.1661373  0.0055166   -30.116  < 2e-16 ***
DESTIN_SZPGSZ04 -0.3046408  0.0058469   -52.103  < 2e-16 ***
DESTIN_SZPGSZ05 -1.5412612  0.0093261  -165.264  < 2e-16 ***
DESTIN_SZPLSZ01 -0.3439667  0.0083504   -41.192  < 2e-16 ***
DESTIN_SZPLSZ02 -1.7574919  0.0154244  -113.942  < 2e-16 ***
DESTIN_SZPLSZ03 -0.3455776  0.0112089   -30.831  < 2e-16 ***
DESTIN_SZPLSZ04 -2.0749385  0.0141153  -146.999  < 2e-16 ***
DESTIN_SZPLSZ05 -0.4855216  0.0134069   -36.214  < 2e-16 ***
DESTIN_SZPNSZ01  0.0117816  0.0083558     1.410 0.158543    
DESTIN_SZPNSZ02  0.7389858  0.0089823    82.272  < 2e-16 ***
DESTIN_SZPNSZ03 -0.4708719  0.0098588   -47.761  < 2e-16 ***
DESTIN_SZPNSZ04  1.3156771  0.0111200   118.316  < 2e-16 ***
DESTIN_SZPNSZ05  0.9881886  0.0153169    64.516  < 2e-16 ***
DESTIN_SZPRSZ01 -1.0678999  0.0098295  -108.642  < 2e-16 ***
DESTIN_SZPRSZ02  0.0650279  0.0063927    10.172  < 2e-16 ***
DESTIN_SZPRSZ03  0.6348138  0.0050147   126.592  < 2e-16 ***
DESTIN_SZPRSZ04 -0.3640286  0.0097572   -37.309  < 2e-16 ***
DESTIN_SZPRSZ05  0.0380410  0.0062577     6.079 1.21e-09 ***
DESTIN_SZPRSZ06  0.3153712  0.0068742    45.877  < 2e-16 ***
DESTIN_SZPRSZ07 -1.6669973  0.0145573  -114.513  < 2e-16 ***
DESTIN_SZPRSZ08 -0.6170648  0.0078424   -78.683  < 2e-16 ***
DESTIN_SZQTSZ01 -0.5496582  0.0098285   -55.925  < 2e-16 ***
DESTIN_SZQTSZ02 -0.7318114  0.0086807   -84.303  < 2e-16 ***
DESTIN_SZQTSZ03 -0.5893064  0.0084789   -69.503  < 2e-16 ***
DESTIN_SZQTSZ04 -0.7103906  0.0085341   -83.242  < 2e-16 ***
DESTIN_SZQTSZ05 -0.4721472  0.0078164   -60.405  < 2e-16 ***
DESTIN_SZQTSZ06 -0.6591466  0.0080069   -82.322  < 2e-16 ***
DESTIN_SZQTSZ07 -0.9540454  0.0126807   -75.236  < 2e-16 ***
DESTIN_SZQTSZ08  0.4508867  0.0064870    69.507  < 2e-16 ***
DESTIN_SZQTSZ09 -0.4061810  0.0075485   -53.810  < 2e-16 ***
DESTIN_SZQTSZ10  0.1351889  0.0068202    19.822  < 2e-16 ***
DESTIN_SZQTSZ11  0.3181553  0.0067958    46.816  < 2e-16 ***
DESTIN_SZQTSZ12 -0.1055766  0.0095576   -11.046  < 2e-16 ***
DESTIN_SZQTSZ13  0.5199663  0.0071928    72.290  < 2e-16 ***
DESTIN_SZQTSZ14  0.6086332  0.0078537    77.496  < 2e-16 ***
DESTIN_SZQTSZ15  1.3906866  0.0092250   150.753  < 2e-16 ***
DESTIN_SZRCSZ01 -0.0862091  0.0085363   -10.099  < 2e-16 ***
DESTIN_SZRCSZ06 -1.0186282  0.0211113   -48.250  < 2e-16 ***
DESTIN_SZRVSZ01 -1.5294454  0.0179337   -85.283  < 2e-16 ***
DESTIN_SZRVSZ02 -2.3607754  0.0355628   -66.383  < 2e-16 ***
DESTIN_SZRVSZ03 -1.5266254  0.0156276   -97.688  < 2e-16 ***
DESTIN_SZRVSZ04 -1.0986565  0.0168695   -65.127  < 2e-16 ***
DESTIN_SZRVSZ05 -2.4004418  0.0320917   -74.799  < 2e-16 ***
DESTIN_SZSBSZ01 -1.4023966  0.0109496  -128.078  < 2e-16 ***
DESTIN_SZSBSZ02 -1.3899893  0.0090891  -152.929  < 2e-16 ***
DESTIN_SZSBSZ03  0.4509008  0.0059864    75.321  < 2e-16 ***
DESTIN_SZSBSZ04  0.1796309  0.0070142    25.610  < 2e-16 ***
DESTIN_SZSBSZ05 -1.3159699  0.0096485  -136.391  < 2e-16 ***
DESTIN_SZSBSZ06 -1.7705263  0.0253064   -69.964  < 2e-16 ***
DESTIN_SZSBSZ07 -0.7471529  0.0238628   -31.310  < 2e-16 ***
DESTIN_SZSBSZ08  0.7884520  0.0069638   113.221  < 2e-16 ***
DESTIN_SZSBSZ09  0.0131702  0.0066350     1.985 0.047150 *  
DESTIN_SZSESZ02 -0.7247347  0.0060626  -119.541  < 2e-16 ***
DESTIN_SZSESZ03  0.1032728  0.0048330    21.368  < 2e-16 ***
DESTIN_SZSESZ04 -1.0992420  0.0068328  -160.878  < 2e-16 ***
DESTIN_SZSESZ05 -0.8374712  0.0058155  -144.006  < 2e-16 ***
DESTIN_SZSESZ06 -0.5531619  0.0074766   -73.985  < 2e-16 ***
DESTIN_SZSESZ07 -3.0328672  0.0246371  -123.101  < 2e-16 ***
DESTIN_SZSGSZ01 -0.1933777  0.0068235   -28.340  < 2e-16 ***
DESTIN_SZSGSZ02 -0.3000845  0.0060284   -49.779  < 2e-16 ***
DESTIN_SZSGSZ03 -0.4322879  0.0057308   -75.433  < 2e-16 ***
DESTIN_SZSGSZ04 -0.1214792  0.0056548   -21.482  < 2e-16 ***
DESTIN_SZSGSZ05 -2.0309074  0.0114993  -176.611  < 2e-16 ***
DESTIN_SZSGSZ06  0.6592095  0.0046364   142.182  < 2e-16 ***
DESTIN_SZSGSZ07 -0.4618538  0.0062027   -74.460  < 2e-16 ***
DESTIN_SZSISZ01 -0.5227257  0.0293399   -17.816  < 2e-16 ***
DESTIN_SZSKSZ01 -0.4797341  0.0091087   -52.668  < 2e-16 ***
DESTIN_SZSKSZ02  0.8477357  0.0067821   124.996  < 2e-16 ***
DESTIN_SZSKSZ03 -0.2477566  0.0074817   -33.115  < 2e-16 ***
DESTIN_SZSKSZ04 -1.3315992  0.0167055   -79.710  < 2e-16 ***
DESTIN_SZSKSZ05 -0.3519096  0.0131326   -26.797  < 2e-16 ***
DESTIN_SZSLSZ01 -0.8570431  0.0102100   -83.941  < 2e-16 ***
DESTIN_SZSLSZ04 -0.9949105  0.0088280  -112.699  < 2e-16 ***
DESTIN_SZSRSZ01 -1.0260696  0.0154393   -66.458  < 2e-16 ***
DESTIN_SZTHSZ01 -4.2040410  0.0404795  -103.856  < 2e-16 ***
DESTIN_SZTHSZ03 -2.4907000  0.0264056   -94.325  < 2e-16 ***
DESTIN_SZTHSZ04 -3.0701470  0.0244975  -125.325  < 2e-16 ***
DESTIN_SZTHSZ06 -2.5308161  0.0169699  -149.135  < 2e-16 ***
DESTIN_SZTMSZ01 -0.2354889  0.0067201   -35.042  < 2e-16 ***
DESTIN_SZTMSZ02  1.7379292  0.0044573   389.906  < 2e-16 ***
DESTIN_SZTMSZ03  0.9112458  0.0048718   187.043  < 2e-16 ***
DESTIN_SZTMSZ04  1.0731075  0.0048626   220.685  < 2e-16 ***
DESTIN_SZTMSZ05  0.6398583  0.0067321    95.046  < 2e-16 ***
DESTIN_SZTNSZ01 -0.3500456  0.0083835   -41.754  < 2e-16 ***
DESTIN_SZTNSZ02 -1.0573515  0.0112412   -94.060  < 2e-16 ***
DESTIN_SZTNSZ03 -1.4069979  0.0132733  -106.002  < 2e-16 ***
DESTIN_SZTNSZ04 -0.3616604  0.0085207   -42.445  < 2e-16 ***
DESTIN_SZTPSZ01 -0.5919243  0.0071153   -83.190  < 2e-16 ***
DESTIN_SZTPSZ02  0.7083350  0.0046540   152.198  < 2e-16 ***
DESTIN_SZTPSZ03 -0.5746433  0.0069625   -82.534  < 2e-16 ***
DESTIN_SZTPSZ04 -1.5821259  0.0084517  -187.196  < 2e-16 ***
DESTIN_SZTPSZ05 -1.1796256  0.0073039  -161.505  < 2e-16 ***
DESTIN_SZTPSZ06 -0.3968272  0.0077295   -51.339  < 2e-16 ***
DESTIN_SZTPSZ07 -2.1796617  0.0135199  -161.219  < 2e-16 ***
DESTIN_SZTPSZ08 -1.2568483  0.0107267  -117.170  < 2e-16 ***
DESTIN_SZTPSZ09 -0.2446623  0.0080840   -30.265  < 2e-16 ***
DESTIN_SZTPSZ10 -1.2542191  0.0102049  -122.904  < 2e-16 ***
DESTIN_SZTPSZ11 -0.0886883  0.0062888   -14.102  < 2e-16 ***
DESTIN_SZTPSZ12 -0.7211823  0.0075086   -96.048  < 2e-16 ***
DESTIN_SZTSSZ01 -1.6271921  0.0238498   -68.227  < 2e-16 ***
DESTIN_SZTSSZ02 -0.3340439  0.0169137   -19.750  < 2e-16 ***
DESTIN_SZTSSZ03  0.3924580  0.0111060    35.338  < 2e-16 ***
DESTIN_SZTSSZ04  0.4169932  0.0114926    36.283  < 2e-16 ***
DESTIN_SZTSSZ05  1.3206287  0.0120381   109.704  < 2e-16 ***
DESTIN_SZTSSZ06  2.4023725  0.0192840   124.579  < 2e-16 ***
DESTIN_SZWCSZ01  2.0697378  0.0061379   337.206  < 2e-16 ***
DESTIN_SZWCSZ02 -2.0934025  0.0134782  -155.318  < 2e-16 ***
DESTIN_SZWCSZ03 -3.0670149  0.0349748   -87.692  < 2e-16 ***
DESTIN_SZWDSZ01  1.0113215  0.0051461   196.522  < 2e-16 ***
DESTIN_SZWDSZ02 -1.3383793  0.0076482  -174.993  < 2e-16 ***
DESTIN_SZWDSZ03  0.3394361  0.0060396    56.202  < 2e-16 ***
DESTIN_SZWDSZ04 -0.8324928  0.0086019   -96.780  < 2e-16 ***
DESTIN_SZWDSZ05 -0.8279090  0.0083251   -99.447  < 2e-16 ***
DESTIN_SZWDSZ06 -0.2252899  0.0061074   -36.888  < 2e-16 ***
DESTIN_SZWDSZ07 -1.3638599  0.0077990  -174.877  < 2e-16 ***
DESTIN_SZWDSZ08 -0.4350176  0.0077566   -56.083  < 2e-16 ***
DESTIN_SZWDSZ09  0.5461048  0.0060745    89.901  < 2e-16 ***
DESTIN_SZYSSZ01  0.0243093  0.0053476     4.546 5.47e-06 ***
DESTIN_SZYSSZ02 -0.3398962  0.0065947   -51.540  < 2e-16 ***
DESTIN_SZYSSZ03 -0.3694187  0.0074032   -49.900  < 2e-16 ***
DESTIN_SZYSSZ04 -0.5222848  0.0067396   -77.495  < 2e-16 ***
DESTIN_SZYSSZ05 -1.5460539  0.0124899  -123.784  < 2e-16 ***
DESTIN_SZYSSZ06 -1.5556892  0.0127640  -121.881  < 2e-16 ***
DESTIN_SZYSSZ07 -0.8673403  0.0167723   -51.713  < 2e-16 ***
DESTIN_SZYSSZ08  0.5389364  0.0052540   102.577  < 2e-16 ***
DESTIN_SZYSSZ09  0.1199483  0.0055235    21.716  < 2e-16 ***
log(dist)       -1.8906989  0.0005319 -3554.786  < 2e-16 ***
---
Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

(Dispersion parameter for poisson family taken to be 1)

    Null deviance: 36117615  on 14273  degrees of freedom
Residual deviance:  8091747  on 13715  degrees of freedom
AIC: 8177420

Number of Fisher Scoring iterations: 7

We can examine how the constraints hold for destinations this time.

CalcRSquared(dbcSIM$data$TRIPS, dbcSIM$fitted.values)
[1] 0.6883675

Model comparison

Another useful model performance measure for continuous dependent variable is Root Mean Squared Error. In this sub-section, you will learn how to use compare_performance() of performance package

First of all, let us create a list called model_list by using the code chun below.

model_list <- list(unconstrained=uncSIM,
                   originConstrained=orcSIM,
                   destinationConstrained=decSIM,
                   doublyConstrained=dbcSIM)

Next, we will compute the RMSE of all the models in model_list file by using the code chunk below.

compare_performance(model_list,
                    metrics = "RMSE")
# Comparison of Model Performance Indices

Name                   | Model |     RMSE
-----------------------------------------
unconstrained          |   glm | 2503.010
originConstrained      |   glm | 2065.575
destinationConstrained |   glm | 1971.310
doublyConstrained      |   glm | 1487.111

print above reveals that doubly constrained SIM is the best model among all the four SIMs because it has the smallest RMSE value of 1487.111.

Visualising fitted

In this section, you will learn how to visualise the observed values and the fitted values.

Firstly we will extract the fitted values from each model by using the code chunk below.

df <- as.data.frame(uncSIM$fitted.values) %>%
  round(digits = 0)

Next, we will join the values to SIM_data data frame.

SIM_data <- SIM_data %>%
  cbind(df) %>%
  rename(uncTRIPS = "uncSIM$fitted.values")

Repeat the same step by for Origin Constrained SIM (i.e. orcSIM)

df <- as.data.frame(orcSIM$fitted.values) %>%
  round(digits = 0)
SIM_data <- SIM_data %>%
  cbind(df) %>%
  rename(orcTRIPS = "orcSIM$fitted.values")

Repeat the same step by for Destination Constrained SIM (i.e. decSIM)

df <- as.data.frame(decSIM$fitted.values) %>%
  round(digits = 0)
SIM_data <- SIM_data %>%
  cbind(df) %>%
  rename(decTRIPS = "decSIM$fitted.values")

Repeat the same step by for Doubly Constrained SIM (i.e. dbcSIM)

df <- as.data.frame(dbcSIM$fitted.values) %>%
  round(digits = 0)
SIM_data <- SIM_data %>%
  cbind(df) %>%
  rename(dbcTRIPS = "dbcSIM$fitted.values")
unc_p <- ggplot(data = SIM_data,
                aes(x = uncTRIPS,
                    y = TRIPS)) +
  geom_point() +
  geom_smooth(method = lm)

orc_p <- ggplot(data = SIM_data,
                aes(x = orcTRIPS,
                    y = TRIPS)) +
  geom_point() +
  geom_smooth(method = lm)

dec_p <- ggplot(data = SIM_data,
                aes(x = decTRIPS,
                    y = TRIPS)) +
  geom_point() +
  geom_smooth(method = lm)

dbc_p <- ggplot(data = SIM_data,
                aes(x = dbcTRIPS,
                    y = TRIPS)) +
  geom_point() +
  geom_smooth(method = lm)

ggarrange(unc_p, orc_p, dec_p, dbc_p,
          ncol = 2,
          nrow = 2)
`geom_smooth()` using formula = 'y ~ x'
`geom_smooth()` using formula = 'y ~ x'
`geom_smooth()` using formula = 'y ~ x'
`geom_smooth()` using formula = 'y ~ x'