plot_ccdc_ts_bypoly: Plot CCDC (Zhu & Woodcock 2014) time series sample by...

View source: R/plot_ccdc_ts.R

plot_ccdc_ts_bypolyR Documentation

Plot CCDC (Zhu & Woodcock 2014) time series sample by polygon.

Description

Provided a CCDC image and a polygon layer with some category field, this function plots a sample of the pixels with each polygon grouped by category, indicated by the 'catg_col' parameter.

Usage

plot_ccdc_ts_bypoly(
  ccdc_img,
  ccdc_img_date,
  zone_poly,
  catg_col,
  days = 730,
  band,
  N = 60
)

Arguments

ccdc_img

(SpatRaster,stars) The CCDC image for which to extract coefficients, for one segment only, such as the output from 'gen_latest_ccdc_rast'.

ccdc_img_date

(character) A representation of the CCDC image date that can be interpreted by as.Date()

zone_poly

(SpatVector,sf) Polygons for which to plot CCDC time series sample, by category.

catg_col

(Character) The name of the column that defines the category of each polygon.

days

The number of days for which to plot the CCDC time series, defaults to 730 (2 years)

band

band (character) The name of the band for which to extract CCDC coefficients. One of 'blue', 'green', 'red' 'nir', 'swir1','swir2' or 'therm'.

N

The number of pixels to sample (and plot) for each category.

Value

(void) Plots the CCDC time series for a sample of pixels stratified by polygon category.


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