[R-sig-Geo] Error in bbox(newdata) : object not a >= 2-column array

philipova at imbm.bas.bg philipova at imbm.bas.bg
Tue Mar 14 09:54:29 CET 2017


> Dear David,
Dear R users,
Now R calculates var1.pred as a constatnt:
kriged=krige(Nmin~1,locationsDD,grid,model=fit)

> kriged["var1.pred"]


925  (339003.4, 2988160)  11.22117
926  (339013.4, 2988160)  11.22117
927  (339023.4, 2988160)  11.22117
928  (339033.4, 2988160)  11.22117
929  (339043.4, 2988160)  11.22117
930  (339053.4, 2988160)  11.22117
931  (339063.4, 2988160)  11.22117
932  (339073.4, 2988160)  11.22117
933  (339083.4, 2988160)  11.22117
........................................
7482 (339293.4, 2989180)  11.22117
7483 (339303.4, 2989180)  11.22117
7484 (339313.4, 2989180)  11.22117
7485 (339323.4, 2989180)  11.22117
7486 (339333.4, 2989180)  11.22117
7487 (339343.4, 2989180)  11.22117
7488 (339353.4, 2989180)  11.22117
>
spplot(kriged["var1.pred"])
 Error: unexpected string constant in:
"
spplot(kriged[""

And it cann't give ssplot
Please if anyone can help me!


I was getting this error as well.  The cause was either not having the
> coordinates and coordinate reference system (CRS) set or having the wrong
> CRS.  I did both at the same time so I am not sure which it was.
>
> Is your 'grid' a SpatialPixels object?
>
> Did you run a line like 'coordinates(grid) <- ~x + y'  ?
>
> If so, did you then set the CRS?
>
>
>
> On Sat, Mar 11, 2017 at 7:38 AM, <philipova at imbm.bas.bg> wrote:
>
>> Dear R-Users,
>> Please anyone to help me with this error:
>>
>> kriged=krige(Nmin~1,locationsDD,grid,model=vgm(1,"Exp",150,1))
>> Error in bbox(newdata) : object not a >= 2-column array
>>
>> Thank you so much in advance!
>> Kind Regards
>> Nina Philipova
>> _______________________________________________
>> R-sig-Geo mailing list
>> R-sig-Geo at r-project.org
>> https://stat.ethz.ch/mailman/listinfo/r-sig-geo
>>
>
>
>
> --
> David Warner
> Research Fisheries Biologist
> U.S.G.S. Great Lakes Science Center
> 1451 Green Road
> Ann Arbor, MI 48105
> 734-214-9392
>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: Variogram & Kriging.txt
URL: <https://stat.ethz.ch/pipermail/r-sig-geo/attachments/20170314/c3a979a4/attachment.txt>


More information about the R-sig-Geo mailing list