R Under development (unstable) (2024-07-07 r86880 ucrt) -- "Unsuffered Consequences" Copyright (C) 2024 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > # This file is part of the standard setup for testthat. > # It is recommended that you do not modify it. > # > # Where should you do additional test configuration? > # Learn more about the roles of various files in: > # * https://r-pkgs.org/tests.html > # * https://testthat.r-lib.org/reference/test_package.html#special-files > > library(testthat) > library(hgwrr) Loading required package: sf Linking to GEOS 3.12.1, GDAL 3.8.4, PROJ 9.3.1; sf_use_s2() is TRUE > > test_check("hgwrr") Hierarchical and geographically weighted regression model ========================================================= Formula: y ~ L(g1 + g2) + x1 + (z1 | group) Method: Back-fitting and Maximum likelihood Data: multisampling$data Global Fixed Effects ------------------- Intercept x1 2.799593 0.966264 Local Fixed Effects ------------------- Bandwidth: 10 (nearest neighbours) Coefficient Min 1st Quartile Median 3rd Quartile Max Intercept -2.228035 -1.317095 -1.033530 -0.619987 -0.253209 g1 3.480131 5.185006 7.250047 8.885822 12.724435 g2 -1.961020 0.705599 1.579516 1.813527 2.433680 Random Effects -------------- Groups Name Std.Dev. Corr group Intercept 1.915502 z1 1.915502 0.000000 Residual 1.915502 Other Information ----------------- Number of Obs: 484 Groups: group , 16 Hierarchical and geographically weighted regression model ========================================================= Formula: y ~ L(g1 + g2) + x1 + (z1 | group) Method: Back-fitting and Maximum likelihood Data: multisampling$data Global Fixed Effects ------------------- | Intercept | x1 | | --------- | -------- | | 2.799593 | 0.966264 | Local Fixed Effects ------------------- Bandwidth: 10 (nearest neighbours) | Coefficient | Min | 1st Quartile | Median | 3rd Quartile | Max | | ----------- | --------- | ------------ | --------- | ------------ | --------- | | Intercept | -2.228035 | -1.317095 | -1.033530 | -0.619987 | -0.253209 | | g1 | 3.480131 | 5.185006 | 7.250047 | 8.885822 | 12.724435 | | g2 | -1.961020 | 0.705599 | 1.579516 | 1.813527 | 2.433680 | Random Effects -------------- | Groups | Name | Std.Dev. | Corr | | -------- | --------- | -------- | -------- | | group | Intercept | 1.915502 | | | | z1 | 1.915502 | 0.000000 | | Residual | | 1.915502 | | Other Information ----------------- Number of Obs: 484 Groups: group , 16 Hierarchical and geographically weighted regression model ========================================================= Formula: y ~ L(g1 + g2) + x1 + (z1 | group) Method: Back-fitting and Maximum likelihood Data: multisampling$data Parameter estimates ------------------- Fixed effects: | | Estimated | Sd. Err | t.val | Pr(>|t|) | | | --------- | --------- | ---------- | -------- | -------- | --- | | Intercept | 2.7995933 | 0.25449128 | 11.00074 | 0 | *** | | x1 | 0.9662643 | 0.04676336 | 20.66285 | 0 | *** | Local fixed effects: | | Min | 1st Quartile | Median | 3rd Quartile | Max | | --------- | --------- | ------------ | --------- | ------------ | --------- | | Intercept | -2.228035 | -1.317095 | -1.033530 | -0.619987 | -0.253209 | | g1 | 3.480131 | 5.185006 | 7.250047 | 8.885822 | 12.724435 | | g2 | -1.961020 | 0.705599 | 1.579516 | 1.813527 | 2.433680 | Diagnostics ----------- | rsquared | 0.647098 | | -------- | -------- | | logLik | NaN | | AIC | NaN | Scaled residuals ---------------- | Min | 1Q | Median | 3Q | Max | | --------- | --------- | --------- | -------- | -------- | | -5.447895 | -1.220145 | -0.067784 | 1.253786 | 5.313347 | Other Information ----------------- Number of Obs: 484 Groups: group , 16 [ FAIL 0 | WARN 0 | SKIP 0 | PASS 23 ] > > proc.time() user system elapsed 3.18 0.31 3.50