not.na: is not NA

not.naR Documentation

is not NA

Description

Shortcut method to avoid the two-step !is.na(x)

Usage

## S4 method for signature 'SpatRaster'
not.na(x, falseNA, filename="", ...)

Arguments

x

SpatRaster

falseNA

logical. Should the result be TRUE, NA instead of TRUE, FALSE?

filename

character. Output filename

...

additional arguments for writing files as in writeRaster

Value

SpatRaster

See Also

Compare-methods

Examples

r <- rast(ncols=10, nrows=10, vals=1)
r[10:20] <- NA
x <- not.na(r)

terra documentation built on Oct. 13, 2023, 5:08 p.m.