[R-sig-Geo] error in krig interpolation

temiz temiz at deprem.gov.tr
Thu Apr 5 20:32:02 CEST 2007


when does this error occur ?

 > zz <- krige(formula = log(el1$z) ~ 1, locations = ~x+y , data = el1 
,newdata = mask_SG , model = efitted) Error in function (classes, fdef, 
mtable)  :
        unable to find an inherited method for function "coordinates<-", 
for signature "SpatialPointsDataFrame"


str(el1) gives:

Formal class 'SpatialPointsDataFrame' [package "sp"] with 5 slots
  ..@ data       :'data.frame': 24051 obs. of  4 variables:
  .. ..$ cat: num [1:24051] 1 2 3 4 5 6 7 8 9 10 ...
  .. ..$ x  : num [1:24051] 449114 449204 449262 449263 449276 ...
  .. ..$ y  : num [1:24051] 4590406 4590375 4590117 4590304 4590214 ...
  .. ..$ z  : num [1:24051] 110 110 110 110 110 110 110 110 110 110 ...
  ..@ coords.nrs : num(0)
  ..@ coords     : num [1:24051, 1:2] 449114 449204 449262 449263 449276 ...
  .. ..- attr(*, "dimnames")=List of 2
  .. .. ..$ : NULL
  .. .. ..$ : chr [1:2] "coords.x1" "coords.x2"
  ..@ bbox       : num [1:2, 1:2]  449083 4584531  456552 4591890
  .. ..- attr(*, "dimnames")=List of 2
  .. .. ..$ : chr [1:2] "coords.x1" "coords.x2"
  .. .. ..$ : chr [1:2] "min" "max"
  ..@ proj4string:Formal class 'CRS' [package "sp"] with 1 slots
  .. .. ..@ projargs: chr " +proj=utm +zone=36 +ellps=intl +units=m 
+no_defs"



regards

-- 
Ahmet Temiz


-- 
This message has been scanned for viruses and\ dangerous con...{{dropped}}




More information about the R-sig-Geo mailing list