I try to make a prediction in raster using linear regression based on past rasters.
I get: Error in UseMethod("predict"): no applicable method for 'predict' applied to an object of class "data.frame"
How could I capture the lm() model to feed it to predict()?
## calculate regression in a raster stack (time series)# and predict.#require(raster)require(rgdal)# make the list of rastersrasters
I get: Error in UseMethod("predict"): no applicable method for 'predict' applied to an object of class "data.frame"
How could I capture the lm() model to feed it to predict()?
## calculate regression in a raster stack (time series)# and predict.#require(raster)require(rgdal)# make the list of rastersrasters