Simulated Spatial Multisampling Data (DataFrame)
multisampling.Rd
A simulation data of spatial hierarchical structure and samples overlapping on certain locations.
Usage
data(multisampling)
Format
A list of two items called "data" and "coord". Item "data" is a data frame with 484 observations at 16 locations on the following 6 variables.
y
a numeric vector, dependent variable \(y\)
g1
a numeric vector, group level independent variable \(g_1\)
g2
a numeric vector, group level independent variable \(g_2\)
z1
a numeric vector, sample level independent variable \(z_1\)
x1
a numeric vector, sample level independent variable \(x_1\)
group
a numeric vector, group id of each sample
where g1
and g2
are used to estimate local fixed effects;
x1
is used to estimate global fixed effects
and z1
is used to estimate random effects.
Author
Yigong Hu yigong.hu@bristol.ac.uk
Examples
data(multisampling)
hgwr(formula = y ~ L(g1 + g2) + x1 + (z1 | group),
data = multisampling$data,
coords = multisampling$coords,
bw = 10)
#> Hierarchical and geographically weighted regression model
#> =========================================================
#> Formula: y ~ L(g1 + g2) + x1 + (z1 | group)
#> Method: Back-fitting and Maximum likelihood
#> Data: multisampling$data
#>
#> Fixed Effects
#> -------------
#> Intercept x1
#> 2.844509 0.966059
#>
#> Group-level Spatially Weighted Effects
#> --------------------------------------
#> Bandwidth: 10 (nearest neighbours)
#>
#> Coefficient estimates:
#> Coefficient Min 1st Quartile Median 3rd Quartile Max
#> Intercept -1.430985 -1.350693 -1.140097 -0.911629 -0.727237
#> g1 5.969397 6.328338 7.136143 7.447083 8.481628
#> g2 -0.683021 0.043467 0.887209 1.174541 1.521918
#>
#> Sample-level Random Effects
#> ---------------------------
#> Groups Name Std.Dev. Corr
#> group Intercept 1.921255
#> z1 1.921255 0.000000
#> Residual 1.921255
#> Groups Name Std.Dev. Corr
#> group Intercept 1.921255
#> z1 1.921255 0.000000
#> Residual 1.921255
#>
#> Other Information
#> -----------------
#> Number of Obs: 484
#> Groups: group , 16