Message-ID: <Pine.LNX.4.44.0704051456530.1188-100000@reclus.nhh.no>
Date: 2007-04-05T13:08:31Z
From: Roger Bivand
Subject: problem in krige function
In-Reply-To: <4615448D.5050705@deprem.gov.tr>
On Thu, 5 Apr 2007, temiz wrote:
>
> following the topic GRASS and R kriging interpolation from grass6 tutorial
>
> I came here without problems
>
> But here:
>
> zz <- krige(z ~ 1, locations = el1 , newdata = mask_SG , model = efitted)
> Error in predict.gstat(g, newdata = newdata, block = block, nsim = nsim, :
> var1 : data item in gstat object and newdata have different
> coordinate reference systems
If:
proj4string(el1)
proj4string(mask_SG)
differ, the function will stop you predicting from data declared to be in
one projection to newdata points in a different projection. You can set
them by:
proj4string(mask_SG) <- CRS(proj4string(el1))
(untried). If this does not work, post the commands you used to create the
objects.
Roger
>
> how can I solve this problem ?
>
> regards
>
>
--
Roger Bivand
Economic Geography Section, Department of Economics, Norwegian School of
Economics and Business Administration, Helleveien 30, N-5045 Bergen,
Norway. voice: +47 55 95 93 55; fax +47 55 95 95 43
e-mail: Roger.Bivand at nhh.no