[R-sig-Geo] GGWR (family = Poission): Prediction of unknown location
Zia Ahmed
zua3 at cornell.edu
Tue Feb 21 01:01:51 CET 2012
Hello,
I am trying to predict expected count for a geographical location (file
name: data_181 - test data) from a another data set (data_65 -
work_data) using GGWR poission model. Following R code I used. But No
predicted counts were found in output SDF file. I am new in GGWR.
Help will be appreciated. I attach my data sets here. Thanks
Zia
library(spgwr)
data(data_65) # work data set
data(data_181) # test data set
bw <- ggwr.sel(PopRisk_100TH ~ log10(WAS)*log10(GAS)+
offset(log(population_1000)), coords=cbind(data_65$x, data_65$y),
data=data_65, family=poisson())
coordinates(data.181)<-~x+y
ggwr.181 <- ggwr(PopRisk_100TH ~ log10(WAS)*log10(GAS) +
offset(log(population_1000)), coords=cbind(data.65$x, data.65$y),
data=data.65,family=poisson(),bandwidth=bw,type =
c("response"),fit.points = data.181)
> ggwr.181$SDF
sum.w X.Intercept. log10.wasMean. log10.gasMean.
log10.wasMean..log10.gasMean. dispersion response_resids x y
1 62.50764 -2.36702 1.45678 -2.42768 5.031622 1 NA 2779558
531287.3
2 63.20595 -2.36062 1.451657 -2.39074 4.995947 1 NA 2767150
575319.5
3 62.87379 -2.36683 1.456869 -2.42598 5.026145 1 NA 2798559
563289.6
4 63.13653 -2.36322 1.453891 -2.4054 5.007724 1 NA 2784218
576455.7
5 62.55473 -2.36991 1.459364 -2.44354 5.042596 1 NA 2807095 546223
6 62.85015 -2.36264 1.453169 -2.40282 5.009307 1 NA 2762510
547772.6
7 62.67004 -2.36523 1.455308 -2.4175 5.022374 1 NA 2773146
538941.8
8 62.40817 -2.36266 1.452969 -2.40357 5.013347 1 NA 2745574
520650.3
9 62.02654 -2.36357 1.453601 -2.40908 5.020167 1 NA 2739576
502023.7
10 63.01464 -2.35797 1.449239 -2.37628 4.9865 1 NA 2739005
557044.6
11 62.8022 -2.35943 1.450378 -2.38489 4.995307 1 NA 2739341
542981.4
12 62.95506 -2.36003 1.45098 -2.38804 4.996592 1 NA 2749492
553074.4
--
---------------------
Zia Ahmed, PhD
Research Associate
Department of Crop and Soil Sciences
1002 Bradfield Hall, Cornell University
Ithaca, NY 14853-4203
t. 607.255.9387
f. 607.255.3207
email zua3 at cornell.edu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://stat.ethz.ch/pipermail/r-sig-geo/attachments/20120220/d79b28b6/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: data_65.csv
Type: application/vnd.ms-excel
Size: 4990 bytes
Desc: not available
URL: <https://stat.ethz.ch/pipermail/r-sig-geo/attachments/20120220/d79b28b6/attachment.xlb>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: data_181.csv
Type: application/vnd.ms-excel
Size: 13657 bytes
Desc: not available
URL: <https://stat.ethz.ch/pipermail/r-sig-geo/attachments/20120220/d79b28b6/attachment-0001.xlb>
More information about the R-sig-Geo
mailing list