Open OrdinarySK opened 4 years ago
Try not naming the arguments, as in
krige(lst~longtitude+latitude+slope+evelation, sa, grid.grid, model=fvlst)
I tried again as you said. error:"Error in eval(predvars, data, env) : not find object 'slope' " “slope” is include in sa, why such error occurs?
It needs to be in grid.grid
as well.
I don't quite understand. user manual example krige(log(zinc)~1, meuse, meuse.grid, model = m) The example data "meuse and meuse.grid", meuse.grid as a GRID data not contains zinc, zinc is include in meuse. why is this ok? As far as i am concerned, In my data, "sa" is the sampling points, including other environmental covariates and target variable. “grid.grid” is the gridded study area GRID data, only contains longtitude and latitude. why "slope" needs to be in "grid.grid" as well? So, Is this my idea wrong?
slope
is on the RHS of the formula, meaning it is a predictor; for prediction, you need to have all predictors at prediction locations.
Okay, I understand roughly, thank you.
Excuse me, I have the other question. How do I determine the size of the parameter range when using fit.lmc. Because of my three target variables have different range base on “Spherical” model.
kr.lst <- krige(formula = lst~longtitude+latitude+slope+evelation, data=sa, newdata=grid.grid, model=fvlst)
error information: Error in (function (classes, fdef, mtable) : unable to find an inherited method for function ‘krige’ for signature ‘"formula", "missing"’
my sa contains longtitude,latitude,slope,evelation,lst and so on column grid.grid contains longtitude,latitude fvlst is fit.variogram result