rFillNA: Fill NA values in a raster

Description Usage Arguments Value See Also Examples

View source: R/modify.operators.R

Description

Assign a value to cells with NA

Usage

1
rFillNA(obj, with = 0)

Arguments

obj

[RasterLayer(1)]
The object to modify.

with

[integerish(1)]
value with which NA should be replaced.

Value

a RasterLayer of the same dimension as obj, where value NA has been replaced by value with.

See Also

Other operators to modify cell values: rBinarise, rCategorise, rDistance, rOffset, rPermute, rRange, rSubstitute

Examples

1
2
3
4
input <- rtRasters$continuous
patches <- rPatches(rBinarise(input, thresh = 30))

visualise(raster::stack(patches, rFillNA(patches)))

EhrmannS/rasterTools documentation built on Sept. 4, 2019, 10:34 a.m.