name_ccdc_bands: Name missing CCDC image bands

View source: R/ccdc_synthetic_img.R

name_ccdc_bandsR Documentation

Name missing CCDC image bands

Description

Uses know naming convention to name the bands of a CCDC image exported from Google Earth Engine script in the case that they are missing. Typically only needed for VRTs and CCDC exports of >5 segments.

Usage

name_ccdc_bands(
  ccdc_img = NULL,
  n_seg,
  bands = c("blue", "green", "red", "nir", "swir1", "swir2", "therm"),
  names_only = F
)

Arguments

ccdc_img

(SpatRaster, stars) The CCDC image for which to name bands, can be NULL if names_only is True

n_seg

(integer) The number of CCDC change segments exported by the Google Earth Engine script (!must match N segments in ccdc_img!)

bands

(character) The bands exported from Earth Engine (in order), defaults to c('blue','green','red','nir','swir1','swir2','therm')

names_only

(boolean) Indicates if the renamed image should be returned, or just a char vector of band names (default False)

Value

(SpatRaster) The same CCDC image used as input with missing band names correctly named.


HunterGleason/R.ccdc.tools documentation built on July 1, 2022, 10:37 a.m.