Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- result$mean <- extract(raster, polygons, weights=T, na.rm=F, fun=mean)
- result$cells <- unlist(lapply(extract(raster, polygons, weights=T, na.rm=F),
- FUN = function(x)(length(x[,1]))))
- results$zeros <- unlist(lapply(extract(raster, polygons, weights=T, na.rm=F),
- FUN = function(x)(sum(x[,1]==0))))
Add Comment
Please, Sign In to add comment