landmap
landmap copied to clipboard
Example of how to use predictionLocations argument in predict()?
Can you provide an example of how to use the predictionLocation argument in predict() with an object from train.splearner?
A reproducible version of the issues I am having is below using the meuse demo...
demo(meuse) m <- train.spLearner(meuse["zinc"], covariates=meuse.grid[,c("dist","ffreq")], lambda = 1)
predict(m, predictionLocations = meuse.grid)
returns: Error in [.data.frame
(predictionLocations@data, , object@spModel$features) :
undefined columns selected
predict(m, predictionLocations = meuse.grid[,c("dist","ffreq")])
returns: Error in [.data.frame
(predictionLocations@data, , object@spModel$features) :
undefined columns selected