Multiscale GWR
Usage
gwr_multiscale(
formula,
data,
config = list(mgwr_config()),
criterion = c("CVR", "dCVR"),
optim_bw_range = c(0, Inf),
hatmatrix = T,
retry_times = 5,
max_iterations = 2000,
parallel_method = c("no", "omp"),
parallel_arg = c(0),
verbose = FALSE
)
# S3 method for gwrmultiscalem
plot(x, y, ..., columns)
# S3 method for gwrmultiscalem
coef(object, ...)
# S3 method for gwrmultiscalem
fitted(object, ...)
# S3 method for gwrmultiscalem
residuals(object, ...)
Arguments
- formula
Regresison model.
- data
A
sf
objects.- config
Parameter-specified weighting configuration. It must be a list of
MGWRConfig
objects. Please find more details in the details section.- criterion
Convergence criterion of back-fitting algorithm.
- optim_bw_range
Bounds on bandwidth optimization, a vector of two numeric elements. Set to
NA_real_
to enable default values selected by the algorithm.- hatmatrix
If TRUE, great circle will be caculated.
- retry_times
The number times of continually optimizing each parameter-specific bandwidth even though it meets the criterion of convergence, for avoiding sub-optimal choice due to illusion of convergence.
- max_iterations
Maximum number of iterations in the back-fitting procedure.
- parallel_method
Parallel method.
- parallel_arg
Parallel method argument.
- verbose
Output information level. Can be either
FALSE
or integer values. Higher values will leads to more output information.- x
A "gwrmultiscalem" object.
- y
Ignored.
- ...
Additional arguments passing to
residuals()
.- columns
Column names to plot. If it is missing or non-character value, all coefficient columns are plottd.
- object
A "gwrmultiscalem" object.
Details
Configuration specification
In the multiscale GWR model,
spatial weighting parameters can be specified for each parameter.
There are several ways to make it easy and flexible.
No matter in which way, the config
parameter needs to be a list
of MGWRConfig
elements.
When the config
list is not named, its length needs to be either 1
or the number of independent variables (including the intercept if any).
For the config
of length 1,
its only value will be applied for every independent variable.
For the config
that as long as independent variables,
its values are mapped to variables by position.
In other cases, an error will occur to prevent further process.
When the config
list is named, the names can contain independent-variable names
or a special character ".default"
.
The function will look up config for each parameter according to its name
in the config
list.
If ".default"
can be found in the list,
once names of some parameters are missing in the config
,
the function will use the value of name ".default"
instead.
However, if not all names can be found in config
and the ".default"
name is missing,
an error will occur to prevent further process.
Functions
plot(gwrmultiscalem)
: Plot the result of basic GWR model.coef(gwrmultiscalem)
: Get coefficients of a multiscale GWR model.fitted(gwrmultiscalem)
: Get fitted values of a basic GWR model.residuals(gwrmultiscalem)
: Get residuals of a basic GWR model.
Examples
data(LondonHP)
gwr_multiscale(
formula = PURCHASE ~ FLOORSZ + UNEMPLOY + PROF,
data = LondonHP
)
#> Multiscale Geographically Weighted Regression Model
#> ===================================================
#> Formula: PURCHASE ~ FLOORSZ + UNEMPLOY + PROF
#> Data: LondonHP
#>
#>
#> Parameter-specified Weighting Configuration
#> -------------------------------------------
#> bw unit type kernel longlat p theta optim_bw criterion
#> Intercept 3758.992 Meters Null gaussian FALSE 2 0 TRUE AIC
#> FLOORSZ 1684.743 Meters Null gaussian FALSE 2 0 TRUE AIC
#> UNEMPLOY 45226.177 Meters Null gaussian FALSE 2 0 TRUE AIC
#> PROF 13000.959 Meters Null gaussian FALSE 2 0 TRUE AIC
#> threshold centered
#> Intercept 1.000000e-05 FALSE
#> FLOORSZ 1.000000e-05 TRUE
#> UNEMPLOY 1.000000e-05 TRUE
#> PROF 1.000000e-05 TRUE
#>
#>
#> Summary of Coefficient Estimates
#> --------------------------------
#> Coefficient Min. 1st Qu. Median 3rd Qu. Max.
#> Intercept 125497.191 132762.279 150831.667 168818.165 190110.170
#> FLOORSZ -184.067 997.289 1506.309 1970.043 3027.671
#> UNEMPLOY 310326.670 315433.209 318711.539 320575.312 325930.524
#> PROF 222076.169 236767.029 248433.345 258565.543 274402.517
#>
#>
#> Diagnostic Information
#> ----------------------
#> RSS: 230041770180
#> ENP: 69.67341
#> EDF: 246.3266
#> R2: 0.8715428
#> R2adj: 0.8350606
#> AICc: 7486.598
#>
#>
# Specify more configurations for all variables
m <- gwr_multiscale(
formula = PURCHASE ~ FLOORSZ + UNEMPLOY + PROF,
data = LondonHP,
config = list(mgwr_config(adaptive = TRUE, kernel = "bisquare"))
)
m
#> Multiscale Geographically Weighted Regression Model
#> ===================================================
#> Formula: PURCHASE ~ FLOORSZ + UNEMPLOY + PROF
#> Data: LondonHP
#>
#>
#> Parameter-specified Weighting Configuration
#> -------------------------------------------
#> bw unit type kernel longlat p theta optim_bw criterion
#> Intercept 92 NN Null bisquare FALSE 2 0 TRUE AIC
#> FLOORSZ 19 NN Null bisquare FALSE 2 0 TRUE AIC
#> UNEMPLOY 51 NN Null bisquare FALSE 2 0 TRUE AIC
#> PROF 157 NN Null bisquare FALSE 2 0 TRUE AIC
#> threshold centered
#> Intercept 1.000000e-05 FALSE
#> FLOORSZ 1.000000e-05 TRUE
#> UNEMPLOY 1.000000e-05 TRUE
#> PROF 1.000000e-05 TRUE
#>
#>
#> Summary of Coefficient Estimates
#> --------------------------------
#> Coefficient Min. 1st Qu. Median 3rd Qu. Max.
#> Intercept 128027.588 134315.206 147425.383 168778.168 185788.635
#> FLOORSZ -71.171 999.976 1480.660 1938.071 3736.606
#> UNEMPLOY -537304.673 108123.294 611883.562 902220.559 2303154.999
#> PROF 163822.997 221234.648 246805.452 300170.581 348794.459
#>
#>
#> Diagnostic Information
#> ----------------------
#> RSS: 221062803902
#> ENP: 68.95713
#> EDF: 247.0429
#> R2: 0.8765567
#> R2adj: 0.8419599
#> AICc: 7474.897
#>
#>
# Specify more configurations for each variables
gwr_multiscale(
formula = PURCHASE ~ FLOORSZ + UNEMPLOY + PROF,
data = LondonHP,
config = list(
mgwr_config(adaptive = TRUE, kernel = "bisquare"),
mgwr_config(adaptive = TRUE, kernel = "bisquare"),
mgwr_config(adaptive = TRUE, kernel = "bisquare"),
mgwr_config(adaptive = TRUE, kernel = "bisquare")
))
#> Multiscale Geographically Weighted Regression Model
#> ===================================================
#> Formula: PURCHASE ~ FLOORSZ + UNEMPLOY + PROF
#> Data: LondonHP
#>
#>
#> Parameter-specified Weighting Configuration
#> -------------------------------------------
#> bw unit type kernel longlat p theta optim_bw criterion
#> Intercept 92 NN Null bisquare FALSE 2 0 TRUE AIC
#> FLOORSZ 19 NN Null bisquare FALSE 2 0 TRUE AIC
#> UNEMPLOY 51 NN Null bisquare FALSE 2 0 TRUE AIC
#> PROF 157 NN Null bisquare FALSE 2 0 TRUE AIC
#> threshold centered
#> Intercept 1.000000e-05 FALSE
#> FLOORSZ 1.000000e-05 TRUE
#> UNEMPLOY 1.000000e-05 TRUE
#> PROF 1.000000e-05 TRUE
#>
#>
#> Summary of Coefficient Estimates
#> --------------------------------
#> Coefficient Min. 1st Qu. Median 3rd Qu. Max.
#> Intercept 128027.588 134315.206 147425.383 168778.168 185788.635
#> FLOORSZ -71.171 999.976 1480.660 1938.071 3736.606
#> UNEMPLOY -537304.673 108123.294 611883.562 902220.559 2303154.999
#> PROF 163822.997 221234.648 246805.452 300170.581 348794.459
#>
#>
#> Diagnostic Information
#> ----------------------
#> RSS: 221062803902
#> ENP: 68.95713
#> EDF: 247.0429
#> R2: 0.8765567
#> R2adj: 0.8419599
#> AICc: 7474.897
#>
#>
# Specify configurations by variable names
gwr_multiscale(
formula = PURCHASE ~ FLOORSZ + UNEMPLOY + PROF,
data = LondonHP,
config = list(
FLOORSZ = mgwr_config(bw = 20, adaptive = TRUE, kernel = "bisquare"),
.default = mgwr_config(adaptive = TRUE, kernel = "bisquare")
))
#> Multiscale Geographically Weighted Regression Model
#> ===================================================
#> Formula: PURCHASE ~ FLOORSZ + UNEMPLOY + PROF
#> Data: LondonHP
#>
#>
#> Parameter-specified Weighting Configuration
#> -------------------------------------------
#> bw unit type kernel longlat p theta optim_bw criterion
#> Intercept 92 NN Null bisquare FALSE 2 0 TRUE AIC
#> FLOORSZ 19 NN Initial bisquare FALSE 2 0 TRUE AIC
#> UNEMPLOY 51 NN Null bisquare FALSE 2 0 TRUE AIC
#> PROF 157 NN Null bisquare FALSE 2 0 TRUE AIC
#> threshold centered
#> Intercept 1.000000e-05 FALSE
#> FLOORSZ 1.000000e-05 TRUE
#> UNEMPLOY 1.000000e-05 TRUE
#> PROF 1.000000e-05 TRUE
#>
#>
#> Summary of Coefficient Estimates
#> --------------------------------
#> Coefficient Min. 1st Qu. Median 3rd Qu. Max.
#> Intercept 128027.588 134315.206 147425.383 168778.168 185788.635
#> FLOORSZ -71.171 999.976 1480.660 1938.071 3736.606
#> UNEMPLOY -537304.673 108123.294 611883.562 902220.559 2303154.999
#> PROF 163822.997 221234.648 246805.452 300170.581 348794.459
#>
#>
#> Diagnostic Information
#> ----------------------
#> RSS: 221062803902
#> ENP: 68.95713
#> EDF: 247.0429
#> R2: 0.8765567
#> R2adj: 0.8419599
#> AICc: 7474.897
#>
#>
plot(m)
coef(m)
#> Intercept FLOORSZ UNEMPLOY PROF
#> 0 132661.3 876.79462 -337814.093 186834.2
#> 1 132603.3 872.79592 -361071.642 186230.0
#> 2 132933.1 890.53033 -170970.753 191026.3
#> 3 132935.0 889.11288 -165579.728 191328.2
#> 4 132654.7 872.41309 -335954.503 188238.5
#> 5 130804.1 827.50134 -537108.792 174524.0
#> 6 130819.9 826.18655 -533854.112 174848.1
#> 7 132180.3 834.23736 -466783.520 185163.5
#> 8 130745.0 819.96195 -537304.673 174790.9
#> 9 131537.4 815.81395 -479475.589 180486.0
#> 10 131537.4 815.81395 -479475.589 180486.0
#> 11 131214.4 815.26252 -506704.350 177840.2
#> 12 138534.5 1492.17933 949222.467 222823.6
#> 13 139566.2 1474.64719 953974.390 224232.1
#> 14 139360.2 1477.87042 950460.005 224036.9
#> 15 138379.2 1495.18831 949023.438 222570.8
#> 16 137491.6 1523.85958 949362.126 220753.8
#> 17 137861.2 1509.59126 946817.279 221268.3
#> 18 137685.8 1516.01628 948400.747 221117.9
#> 19 139874.0 1466.84798 950594.866 225156.7
#> 20 137370.0 1530.87449 945914.266 221005.5
#> 21 137205.8 1540.42358 947512.260 220376.7
#> 22 139078.7 1480.52275 944274.256 224142.1
#> 23 137393.5 1530.30600 939529.645 221205.4
#> 24 139330.0 1474.77866 942305.422 224514.1
#> 25 138132.7 1499.95735 939880.739 222283.9
#> 26 139807.5 1462.68059 943485.416 225576.5
#> 27 139589.9 1467.70601 941180.844 225085.3
#> 28 131213.8 2076.11483 45188.174 169920.1
#> 29 131246.9 2064.30569 37881.400 169916.2
#> 30 135303.3 874.17981 759653.784 214162.8
#> 31 131182.1 2085.28432 58683.044 170122.0
#> 32 131220.6 2083.71247 58970.516 169592.3
#> 33 136051.4 908.78070 834885.683 218370.5
#> 34 135897.0 875.78490 806658.940 217939.8
#> 35 134909.4 760.36998 503207.407 211583.3
#> 36 131192.5 2097.53611 72358.774 170040.4
#> 37 135886.3 808.22080 735878.517 217762.4
#> 38 131160.4 2110.60154 86524.144 170514.3
#> 39 131120.1 2112.50252 89693.204 170542.9
#> 40 131199.2 1013.18232 -410780.505 189437.5
#> 41 130970.4 995.46085 -426226.556 188279.1
#> 42 130970.4 995.46085 -426226.556 188279.1
#> 43 130274.1 976.98315 -437132.705 186657.1
#> 44 130618.2 999.97485 -433020.755 187684.8
#> 45 131107.4 2117.94595 98993.431 171113.7
#> 46 131598.2 1025.40347 -365113.904 194171.5
#> 47 130302.2 1014.82109 -426048.716 188398.8
#> 48 130308.8 1635.32854 71978.745 167564.6
#> 49 131158.5 1021.53534 -376287.458 192685.3
#> 50 130713.0 1031.70661 -403017.828 190804.6
#> 51 130713.0 1031.70661 -403017.828 190804.6
#> 52 132024.9 1001.76392 -276432.413 200656.4
#> 53 131180.5 1015.29071 -351264.715 194087.0
#> 54 129901.7 1525.27198 69439.126 168615.9
#> 55 130281.2 1594.69928 119926.527 166285.3
#> 56 141077.7 1673.14265 771521.781 230857.2
#> 57 143356.0 1972.45790 776338.901 233387.3
#> 58 147111.1 2106.72606 717584.685 237711.8
#> 59 143978.7 1979.65789 758299.855 234127.3
#> 60 162078.7 1940.11129 800498.917 256796.5
#> 61 161657.6 1941.34621 797610.831 256472.8
#> 62 161537.8 1943.39624 793530.097 256444.6
#> 63 162177.5 1941.10374 796760.212 257005.5
#> 64 163407.5 1937.56812 802822.160 257891.2
#> 65 161618.0 1944.71608 790354.038 256590.7
#> 66 163613.8 1936.97574 803532.518 258131.1
#> 67 163025.6 1940.15597 799177.825 257645.7
#> 68 162251.2 1941.85841 794324.884 257158.0
#> 69 163495.0 1938.57433 801575.759 258064.6
#> 70 161519.2 1947.93053 785223.811 256586.1
#> 71 163711.7 1940.10607 799176.009 258327.6
#> 72 163003.4 1943.09393 791797.822 257929.9
#> 73 145789.8 2014.35570 592544.362 236960.4
#> 74 164631.5 1936.58602 805476.116 259326.3
#> 75 163056.4 1943.58647 791259.649 258068.5
#> 76 144623.0 1939.95739 574346.807 235709.0
#> 77 147779.2 2066.20581 531365.174 239972.6
#> 78 146834.0 2028.29332 550526.493 238556.4
#> 79 136104.5 647.78510 148704.175 222479.1
#> 80 151347.3 2070.34086 422063.747 245898.2
#> 81 135981.1 881.79311 124792.008 223119.0
#> 82 150085.3 1976.61705 560066.409 244233.3
#> 83 136867.5 999.97618 133265.395 224418.1
#> 84 128027.6 872.07693 669154.669 178128.6
#> 85 129582.1 1095.00340 671852.138 163823.0
#> 86 129547.8 1063.27644 640287.925 165481.3
#> 87 129242.5 1046.63276 750652.843 165753.1
#> 88 129418.0 1025.31390 693845.589 165461.7
#> 89 129236.4 1027.96875 736389.131 165711.7
#> 90 128520.2 834.63267 587063.042 172431.4
#> 91 129551.4 965.17831 612544.719 170036.2
#> 92 129028.4 903.52354 581612.453 166463.1
#> 93 149379.9 1581.53896 590651.718 246406.1
#> 94 129113.6 898.61428 583418.569 166928.9
#> 95 129113.6 898.61428 583418.569 166928.9
#> 96 130269.4 1692.21308 163759.845 200395.8
#> 97 149845.4 1582.50237 599755.642 247744.9
#> 98 129984.3 1329.70095 272438.631 186523.7
#> 99 150409.4 1575.02115 602270.972 248743.5
#> 100 149599.7 1584.59614 597358.582 247204.8
#> 101 150752.8 1570.39049 604231.014 249508.5
#> 102 150139.1 1575.41715 602355.260 248098.4
#> 103 149117.1 1558.40884 570650.248 245729.0
#> 104 130115.6 1625.01094 188419.995 198452.9
#> 105 151291.8 1573.84771 611222.405 250119.2
#> 106 147719.4 1531.67184 497655.860 243144.5
#> 107 130126.4 1610.83386 168009.548 204064.7
#> 108 153182.2 1523.18258 643548.565 253469.5
#> 109 129900.4 1521.71813 263744.443 193998.2
#> 110 130060.9 1598.62578 180438.806 203095.3
#> 111 130070.9 1596.99991 174347.613 204102.6
#> 112 130016.0 1590.32403 181573.120 203978.1
#> 113 179849.6 2141.04457 935804.569 286376.0
#> 114 178933.0 2524.52922 975945.197 281467.0
#> 115 178408.9 2593.23917 988401.338 280593.4
#> 116 178408.9 2593.23917 988401.338 280593.4
#> 117 179024.4 2490.98666 991943.679 281904.3
#> 118 179881.9 2012.09673 921212.616 288775.6
#> 119 179976.8 2119.43161 946965.279 287766.2
#> 120 178981.1 2457.63635 1027383.602 282026.7
#> 121 160840.7 1643.67117 622256.484 269723.7
#> 122 160840.7 1643.67117 622256.484 269723.7
#> 123 162370.0 2004.21501 629844.600 271513.7
#> 124 161786.2 1784.86609 626698.987 271117.1
#> 125 160856.6 1611.11858 631230.317 270408.5
#> 126 179918.2 2382.95228 1035025.797 283860.6
#> 127 179918.2 2382.95228 1035025.797 283860.6
#> 128 163585.4 2776.30757 628092.825 272877.4
#> 129 162995.4 2260.32263 639187.205 273077.0
#> 130 162825.7 1923.75801 643925.119 273589.3
#> 131 162825.7 1923.75801 643925.119 273589.3
#> 132 161909.7 1613.14103 648370.044 273875.1
#> 133 166220.5 3383.00061 633234.270 276643.2
#> 134 163160.8 1735.62551 656803.355 276994.4
#> 135 164856.0 3075.70985 668376.665 277762.2
#> 136 162407.0 1578.76822 663814.976 277466.4
#> 137 164247.1 2136.83145 668774.372 278312.2
#> 138 167226.3 3649.20040 714340.117 280023.7
#> 139 164488.1 2222.48390 672108.612 278860.7
#> 140 162286.7 1548.43672 665054.173 278106.4
#> 141 167262.1 3736.60597 714248.880 281021.8
#> 142 129091.8 1421.65570 68028.075 220276.3
#> 143 137673.1 934.77571 193681.843 241642.6
#> 144 134707.5 861.59018 197651.717 231053.6
#> 145 128878.9 1405.53983 57931.690 220600.4
#> 146 132544.7 810.54161 210757.103 215475.2
#> 147 131281.0 924.56652 213257.414 207671.3
#> 148 138224.0 935.19601 196618.365 243260.8
#> 149 132920.1 783.31127 209133.035 217891.8
#> 150 132675.0 817.40207 210734.674 216692.8
#> 151 128815.7 1400.35203 51382.878 221263.9
#> 152 137933.5 927.58820 197510.270 242322.0
#> 153 132453.6 866.86841 214979.199 216251.6
#> 154 133559.2 790.32856 210729.152 221694.1
#> 155 135182.0 840.60977 204762.656 231269.7
#> 156 135182.0 840.60977 204762.656 231269.7
#> 157 182912.7 1912.73130 1278769.814 296256.5
#> 158 135933.6 865.80800 202975.540 235033.0
#> 159 134005.1 807.56964 211912.021 223183.6
#> 160 133110.7 872.86436 214032.414 219289.8
#> 161 133961.6 831.03713 213142.624 223599.2
#> 162 132549.5 919.39480 217753.299 216247.5
#> 163 183199.4 1873.70232 1268797.836 297406.6
#> 164 135200.3 807.09185 211252.261 231262.7
#> 165 132366.8 941.54906 215400.624 214741.4
#> 166 183868.0 1634.95706 1425396.976 296916.0
#> 167 132513.3 952.36269 212997.968 215427.1
#> 168 128871.8 1037.41838 117253.157 218066.4
#> 169 128733.1 1061.79001 96491.704 218747.9
#> 170 129124.9 1348.35979 37724.023 223577.0
#> 171 184613.2 1819.15099 1516759.450 297711.9
#> 172 129073.5 1018.63065 85378.984 219861.0
#> 173 184950.7 1801.95933 1375391.386 300223.6
#> 174 129252.6 1029.57572 82950.278 220375.5
#> 175 185326.3 2302.94938 1575150.043 300537.9
#> 176 172353.1 527.10551 1006000.389 299367.8
#> 177 173119.0 549.26919 1041399.808 300117.6
#> 178 172712.7 527.06845 1050800.311 300029.4
#> 179 170913.1 351.05469 1094224.259 299549.4
#> 180 170264.5 262.04141 1166868.661 299915.5
#> 181 185726.2 2598.05622 1554600.932 308509.1
#> 182 184377.6 2624.41598 1712845.881 308639.2
#> 183 182143.7 2662.08140 2188695.583 310582.6
#> 184 181735.5 2645.70313 2303154.999 310938.5
#> 185 183869.9 2720.83182 1737836.342 311358.5
#> 186 180699.7 2491.77524 2202382.388 313353.9
#> 187 185284.3 2790.55879 1467910.751 312011.3
#> 188 185284.3 2790.55879 1467910.751 312011.3
#> 189 159497.3 -71.17115 546104.724 290368.4
#> 190 185788.6 2843.27744 1563519.915 313217.7
#> 191 185247.5 2838.97698 1604694.376 313352.4
#> 192 184919.6 2852.91474 1614858.688 313845.3
#> 193 183072.6 2755.60806 1892848.457 314713.5
#> 194 138247.3 1223.96042 200662.875 235686.3
#> 195 171696.1 232.78870 1113459.680 309335.5
#> 196 164454.7 1517.08138 843362.780 299415.7
#> 197 177474.6 1342.71667 1074679.731 313678.4
#> 198 177561.7 1334.47275 1076856.580 313785.9
#> 199 177573.2 1333.68413 1077606.968 313801.7
#> 200 177596.2 1328.99173 1077453.670 313833.7
#> 201 177324.3 1349.97874 1069710.348 314007.6
#> 202 177366.3 1345.22296 1071741.949 314169.5
#> 203 133756.1 1122.08838 -34685.532 232710.2
#> 204 154656.0 1484.45773 574110.961 262718.2
#> 205 136816.5 998.03652 37968.901 235832.1
#> 206 136816.5 998.03652 37968.901 235832.1
#> 207 136100.9 1004.93564 19158.344 235003.7
#> 208 172791.5 1540.95202 1046250.786 332685.2
#> 209 173259.9 1426.89299 1016803.200 334052.7
#> 210 172978.1 1440.01535 1025312.942 333412.5
#> 211 134074.3 1106.82225 -44102.428 233266.3
#> 212 175450.9 1334.83920 902035.911 325616.3
#> 213 172648.6 1433.01780 1016153.406 335083.6
#> 214 136444.8 1007.69152 2323.200 235804.4
#> 215 172325.2 1443.98669 1017384.877 336265.0
#> 216 172601.4 1442.64673 992217.849 336038.7
#> 217 172296.6 1461.54160 1007412.272 336785.5
#> 218 167651.8 2359.72819 1024727.453 302513.4
#> 219 134923.3 1134.16949 -45397.613 234285.3
#> 220 134873.8 1137.62593 -47087.555 234225.9
#> 221 172322.1 1444.87869 991552.714 337078.2
#> 222 134454.9 1114.02786 -51217.122 233775.8
#> 223 174726.6 1631.93779 296669.289 333432.7
#> 224 171927.0 1455.78322 999061.750 338523.2
#> 225 171860.4 1463.81297 1002308.985 338705.1
#> 226 163589.3 2264.73423 979542.135 295184.9
#> 227 174442.4 1481.68762 294329.740 334227.8
#> 228 174965.5 1395.35811 902405.207 326574.1
#> 229 169383.3 2575.61114 1046891.954 311998.7
#> 230 169008.3 2579.63220 1044519.604 312013.1
#> 231 174829.0 1411.84198 898796.493 326937.5
#> 232 168680.1 2579.62358 1043093.604 311171.8
#> 233 163313.7 2305.31356 984536.696 295819.9
#> 234 174869.8 1409.65625 936896.706 326380.3
#> 235 165963.7 2417.56264 1018833.121 302565.1
#> 236 174818.8 1418.64693 937232.084 326482.5
#> 237 168941.8 2636.35296 1038466.759 313504.0
#> 238 168876.2 2624.63930 1039044.061 312814.1
#> 239 171554.5 1365.27581 298941.152 340734.7
#> 240 135308.7 942.30591 -62653.455 235801.5
#> 241 135267.7 943.06057 -62546.118 235740.8
#> 242 135267.7 943.06057 -62546.118 235740.8
#> 243 135188.2 945.52334 -62171.838 235630.7
#> 244 135529.6 937.96437 -61983.503 236166.9
#> 245 135718.9 927.43049 -64441.640 236486.7
#> 246 135577.4 939.80745 -63051.507 236278.0
#> 247 173573.6 1539.90254 888069.790 330125.7
#> 248 135285.3 947.62116 -61536.002 235877.8
#> 249 173160.5 1548.92790 835460.410 331401.6
#> 250 170322.8 1541.79753 356558.727 343599.2
#> 251 136027.3 854.07154 -63770.409 237016.9
#> 252 135767.3 937.45132 -64683.768 236641.1
#> 253 135767.3 937.45132 -64683.768 236641.1
#> 254 173119.1 1558.47608 837937.338 331465.4
#> 255 136311.1 791.28476 -61128.526 237438.8
#> 256 135970.3 896.59581 -63329.877 236977.3
#> 257 135767.5 952.73950 -63021.779 236720.7
#> 258 173291.9 1570.52546 882933.116 330730.8
#> 259 134165.6 1748.12865 -33005.158 234525.6
#> 260 169417.5 1871.97771 449941.806 346376.7
#> 261 135858.3 973.83977 -60383.731 236977.2
#> 262 134180.8 1771.54154 -32389.190 234568.0
#> 263 134095.3 1806.46878 -29728.086 234467.9
#> 264 169593.0 1838.40626 344825.760 344129.0
#> 265 140380.1 1006.69967 13034.385 242636.1
#> 266 136061.7 961.78741 -59078.151 237310.0
#> 267 173069.0 1593.05654 872568.824 331274.6
#> 268 172720.2 1628.34443 836591.548 332252.2
#> 269 140082.2 1012.05210 -1312.869 242399.5
#> 270 135814.3 966.83421 -57746.827 237013.5
#> 271 139732.2 1015.91621 -22265.435 242097.0
#> 272 136043.5 1004.32248 -55828.370 237441.0
#> 273 134449.6 1830.23418 -33735.657 235018.9
#> 274 136969.8 787.24726 -54467.118 238497.4
#> 275 134477.6 1868.61966 -32229.239 235097.5
#> 276 141816.1 1055.01589 46065.451 244630.5
#> 277 139294.9 1031.79193 -60644.383 241747.0
#> 278 166039.7 2527.87498 891144.787 342468.8
#> 279 165504.9 2504.87533 911595.609 336104.5
#> 280 170682.1 1503.68509 636825.370 340391.3
#> 281 165577.4 2521.56989 869387.174 343757.8
#> 282 170704.3 1534.56268 682969.572 339609.6
#> 283 170704.3 1534.56268 682969.572 339609.6
#> 284 170525.1 1496.84136 630045.595 341393.4
#> 285 170295.2 1480.65975 574861.411 342269.1
#> 286 170295.2 1480.65975 574861.411 342269.1
#> 287 170587.1 1526.21749 669102.413 340560.0
#> 288 170191.9 1489.31812 569210.783 342638.0
#> 289 165185.0 2530.44646 847233.190 345650.6
#> 290 165185.0 2530.44646 847233.190 345650.6
#> 291 164925.9 2472.25050 888981.390 335331.0
#> 292 147600.8 1371.29603 334182.825 252737.0
#> 293 147600.8 1371.29603 334182.825 252737.0
#> 294 166474.9 2495.53085 435073.550 348794.5
#> 295 147078.8 1402.73518 341001.069 252375.3
#> 296 146739.5 1399.26260 350910.774 251967.2
#> 297 165925.1 2367.63491 445391.694 348388.7
#> 298 161515.0 1445.39286 784830.599 321281.6
#> 299 150219.4 1379.46329 578091.287 257472.1
#> 300 165946.3 2531.66096 443316.109 348661.0
#> 301 147115.9 1455.41549 376462.759 252532.7
#> 302 149811.0 1442.15520 553928.155 256923.4
#> 303 161427.8 1434.11253 761038.485 321449.8
#> 304 144474.9 1354.74737 121033.851 249334.8
#> 305 161491.1 1547.04466 768913.663 326155.0
#> 306 161491.1 1547.04466 768913.663 326155.0
#> 307 148660.1 1664.67071 502451.895 255246.4
#> 308 146668.5 1501.60075 406367.291 252254.4
#> 309 147250.0 1655.11218 452474.835 253191.2
#> 310 160153.4 1231.19275 649041.379 315365.8
#> 311 160042.8 1201.41236 656183.323 312548.3
#> 312 159184.6 1001.14699 654116.185 303303.0
#> 313 157629.0 946.85364 693262.250 287248.4
#> 314 157299.8 945.10514 701922.153 284747.7
#> 315 157406.7 946.32289 686776.682 286222.6
fitted(m)
#> [1] 277562.9 274332.6 275273.1 303083.5 304129.8 283928.9 268348.8 335148.3
#> [9] 281598.6 418258.1 345650.6 335161.7 422821.6 406933.1 362427.6 403471.2
#> [17] 364156.1 389628.7 376227.8 412851.8 522093.4 423523.6 379836.4 467246.7
#> [25] 410776.3 340195.6 343773.4 328846.5 501695.6 375368.0 292410.1 390762.3
#> [33] 348752.8 306388.1 285643.0 350049.9 501191.2 326617.8 454548.4 524544.8
#> [41] 395328.4 244900.0 237931.7 277090.8 272251.2 551285.9 235708.0 228197.7
#> [49] 457946.4 263388.1 322201.5 248950.4 209400.7 219749.2 402783.0 446128.2
#> [57] 362834.1 420250.3 453689.5 441842.5 525336.5 460721.0 412669.0 409906.4
#> [65] 471733.8 445826.4 448809.7 457711.0 520710.4 396350.0 599627.8 548022.2
#> [73] 508341.1 455553.7 407426.1 424926.7 422307.9 425119.0 438489.1 292043.8
#> [81] 484824.4 270484.9 559417.4 293390.7 271309.0 367592.2 308705.7 306013.7
#> [89] 283304.5 300110.8 285270.3 345505.2 270102.5 410665.8 330107.4 315729.6
#> [97] 351780.9 375946.3 354111.4 394018.5 445154.8 385089.1 361998.9 528636.8
#> [105] 302040.8 405414.1 385852.4 469673.1 363947.7 340331.5 379624.9 349419.2
#> [113] 345813.5 449898.6 559229.2 519801.7 582039.5 615181.2 441402.8 430413.4
#> [121] 560518.5 470740.3 413211.8 462591.3 457413.8 402337.5 686824.3 648697.0
#> [129] 454941.0 542544.4 477301.4 477301.4 445523.9 575409.7 508778.2 642267.0
#> [137] 459221.8 483723.7 927409.8 503064.0 530172.1 680291.1 317092.7 326160.0
#> [145] 309392.8 369069.7 301489.5 300531.5 285228.7 272819.1 365588.5 382430.7
#> [153] 292687.6 317886.6 275353.8 279274.8 297768.2 470435.9 267786.5 318523.5
#> [161] 336763.6 305358.3 279107.3 444530.6 291053.1 350723.3 512700.2 299137.7
#> [169] 323844.8 292433.8 331684.1 534308.2 330825.9 469890.6 258214.5 467686.1
#> [177] 458108.8 420752.2 473160.5 411721.7 406638.8 721410.7 611242.3 576290.4
#> [185] 675685.2 671577.1 736239.1 587845.6 632494.6 299640.2 634026.2 833958.2
#> [193] 779294.8 576719.5 415074.8 419530.3 424636.5 494239.3 415945.4 488783.9
#> [201] 481983.3 365374.6 407068.9 294117.1 387608.8 307755.3 335700.3 299653.5
#> [209] 530364.4 731094.6 552451.7 257460.7 417259.6 560381.8 279004.3 599412.1
#> [217] 493791.1 570552.2 536542.0 406458.8 325025.1 512921.9 241281.5 417804.9
#> [225] 485404.6 565077.5 540924.8 421917.3 412618.2 598056.4 654543.2 546280.8
#> [233] 532499.6 522627.8 421673.1 678689.5 442169.0 615493.9 889792.9 497809.5
#> [241] 251810.0 245191.7 246134.8 221504.2 264089.6 268500.2 317802.2 468659.2
#> [249] 276507.9 545584.1 409988.9 285985.4 252313.0 304810.3 518631.4 314484.9
#> [257] 303007.2 263402.0 471919.6 361742.0 443329.3 289197.3 344230.2 355726.8
#> [265] 529292.5 347131.7 300143.8 607221.0 555844.7 423672.1 308055.1 326576.5
#> [273] 302213.3 376230.3 285530.0 396465.9 382140.4 367264.8 570328.8 558277.4
#> [281] 415723.7 970460.0 443869.3 428523.6 457414.1 395670.5 397151.2 383346.2
#> [289] 471838.4 600273.9 605334.8 499272.0 380362.6 361164.4 525476.2 377693.0
#> [297] 348074.7 560674.5 469454.1 372077.3 783806.5 415712.3 371076.2 481358.5
#> [305] 344377.9 502467.9 502467.9 392686.2 315369.4 365850.5 427819.6 400509.3
#> [313] 447059.2 447888.1 366299.1 544350.3
residuals(m)
#> [1] -120562.87 -160832.60 -193523.06 -153083.54 -114129.83 -123978.85
#> [7] -118353.77 -95198.28 -128598.59 -168308.08 -98650.64 -74161.74
#> [13] -319821.57 -283433.09 -259427.55 -303471.22 -274206.10 -294628.66
#> [19] -286727.76 -276851.84 -252093.44 -288523.58 -264836.41 -272246.71
#> [25] -286776.32 -256195.62 -256773.43 -264896.46 -271695.63 -233367.96
#> [31] -196410.07 -263762.26 -236752.80 -211388.13 -215642.95 -190049.87
#> [37] -314691.17 -206617.83 -234548.43 -287044.82 -165328.43 -167899.97
#> [43] -192931.75 -152090.79 -97251.18 -191285.86 -180208.04 -143197.66
#> [49] -208946.36 -193438.11 -172251.53 -141950.36 -142900.70 -150249.21
#> [55] -207782.96 -201128.24 -257834.07 -295250.29 -273739.47 -318842.46
#> [61] -300336.51 -313720.98 -303669.02 -319956.38 -336733.84 -316826.36
#> [67] -313809.72 -320711.04 -405710.43 -316399.96 -250627.84 -368022.19
#> [73] -302341.13 -325554.69 -318426.06 -291926.75 -298807.93 -343118.99
#> [79] -338489.13 -197543.80 -283824.40 -199484.86 -314417.38 -184890.71
#> [85] -183358.99 -246092.15 -199705.66 -201018.73 -183354.52 -202110.79
#> [91] -195270.30 -176505.19 -140107.47 -280665.81 -203107.43 -190729.60
#> [97] -217780.88 -285946.33 -219611.37 -296518.51 -278654.84 -262089.14
#> [103] -264498.92 -255636.83 -218040.76 -253414.07 -305852.44 -234673.15
#> [109] -249447.71 -241381.45 -221624.87 -261419.19 -225813.55 -360398.56
#> [115] -379229.23 -404801.74 -437039.48 -365231.19 -326402.79 -343413.42
#> [121] -405518.51 -293740.27 -250211.78 -377591.29 -302413.85 -261337.51
#> [127] -348824.27 -378697.03 -346941.02 -276044.45 -332301.44 -332301.44
#> [133] -335523.86 -422909.68 -378778.16 -407266.99 -302721.76 -305223.75
#> [139] -407409.78 -331064.02 -320172.09 -490291.10 -217092.67 -212049.02
#> [145] -137392.81 -199069.73 -161489.53 -200536.55 -198228.72 -189819.11
#> [151] -203588.51 -239430.68 -205187.57 -227886.57 -161353.80 -171774.76
#> [157] -199768.17 -346435.88 -195286.47 -180023.48 -158263.64 -173358.26
#> [163] -209107.30 -341530.65 -187553.14 -152723.30 -402700.24 -170137.71
#> [169] -193849.75 -217433.79 -236689.10 -317308.19 -201825.92 -372890.63
#> [175] -193214.49 -357686.10 -278108.77 -248752.25 -178160.54 -126721.72
#> [181] -229138.82 -446410.70 -473742.27 -462290.45 -462435.17 -496577.11
#> [187] -516239.09 -430845.62 -459494.56 -114640.24 -444026.17 -408958.21
#> [193] -399294.84 -455719.49 -215074.78 -199530.31 -259636.48 -248739.29
#> [199] -300995.40 -333783.92 -344983.26 -312374.62 -305068.95 -202122.12
#> [205] -239108.83 -176755.28 -200700.30 -204653.47 -319364.37 -341094.63
#> [211] -317451.68 -183960.71 -319259.59 -282381.79 -191004.34 -329412.07
#> [217] -351791.12 -302552.21 -326542.03 -193458.79 -201025.11 -339421.94
#> [223] -196281.47 -334804.87 -326404.59 -270077.49 -414424.79 -281917.26
#> [229] -315118.19 -408106.41 -464543.20 -328280.79 -417499.62 -357627.82
#> [235] -287673.09 -398489.55 -310168.95 -425493.94 -389792.89 -317809.49
#> [241] -181814.96 -187441.72 -191134.78 -162004.22 -190589.63 -192500.20
#> [247] -227802.18 -363659.25 -170007.93 -307584.10 -305988.87 -175985.43
#> [253] -192813.04 -172310.31 -328631.40 -189484.87 -175007.19 -181401.96
#> [259] -339919.65 -301746.96 -325329.25 -171197.33 -249730.20 -276726.78
#> [265] -306792.54 -162131.72 -166893.83 -315221.01 -312844.67 -208672.09
#> [271] -181055.11 -178576.54 -166213.30 -241230.29 -160530.01 -272465.91
#> [277] -212640.44 -156764.78 -410328.77 -403277.37 -340723.66 -402959.98
#> [283] -323919.26 -309523.64 -317414.14 -295720.54 -298651.20 -302396.21
#> [289] -304838.39 -438273.95 -422334.84 -380272.04 -237362.56 -264214.42
#> [295] -390476.22 -220192.97 -240074.75 -445674.52 -365954.13 -236577.28
#> [301] -373806.48 -235712.30 -294076.16 -339108.51 -260377.87 -342467.92
#> [307] -342467.92 -279686.24 -247369.41 -281850.51 -277819.58 -290509.30
#> [313] -209559.17 -192888.14 -236299.06 -264350.32