Rscript : Why is Error in UseMethod(“extract_”) : being indicated when attempting to use raster::extract?
问题 I attempting to use raster package's extract method to extract values from a Raster* object. RStudioPrompt> jpnpe <- extract(jpnp, jpnb, fun = mean, na.rm = T) where jpnp is the raster object and jpnb is SpatialPolygonsDataFrame However the following error is indicated: Error in UseMethod("extract_") : no applicable method for 'extract_' applied to an object of class "c('RasterStack', 'Raster', 'RasterStackBrick', 'BasicRaster')" How can I get passed this error? 回答1: Issue may be due to