Learn R Programming

sits (version 1.12.0)

sits_transmute_bands: Add new sits bands and drops existing.

Description

Adds new bands and drops existing in the time series of a sits tibble using dplyr::transmute function.

Usage

sits_transmute_bands(data.tb, ...)

Arguments

data.tb

A sits tibble.

...

Pair expressions in the format `name = value`. See mutate help for more details.

Value

A sits tibble with same samples and the new bands.

Examples

Run this code
# NOT RUN {
# Retrieve data for time series with label samples in Mato Grosso in Brazil
data(samples_mt_9classes)
# Generate a new image with the SAVI (Soil-adjusted vegetation index)
savi.tb <- sits_transmute_bands(samples_mt_9classes, savi = (1.5*(nir - red)/(nir + red + 0.5)))
# }

Run the code above in your browser using DataLab