scale_doy: Scale DOY

Description Usage Arguments Value See Also Examples

View source: R/scale.R

Description

Scale the day of the year to 0-1 (like NDVI).

Usage

1
scale_doy(DT, doy = "DayOfYear")

Arguments

DT

data.table of NDVI time series

doy

julian day column. default is 'DayOfYear'.

Value

data.table with appended 't' column of 0-1 scaled day of year.

See Also

Other scale: scale_ndvi()

Examples

1
2
3
4
5
6
7
8
# Load data.table
library(data.table)

# Read in example data
ndvi <- fread(system.file("extdata", "sampled-ndvi-MODIS-MOD13Q1.csv", package = "irg"))

# Scale DOY
scale_doy(ndvi)

irg documentation built on Dec. 22, 2021, 9:06 a.m.