powered by
Shortcut method to avoid the two-step !is.na(x)
!is.na(x)
# S4 method for SpatRaster not.na(x, falseNA, filename="", ...)
SpatRaster
logical. Should the result be TRUE, NA instead of TRUE, FALSE?
TRUE, NA
TRUE, FALSE
character. Output filename
additional arguments for writing files as in writeRaster
writeRaster
Compare-methods
r <- rast(ncols=10, nrows=10, vals=1) r[10:20] <- NA x <- not.na(r)
Run the code above in your browser using DataLab