cumsum_rb: cumsum_rb

View source: R/growingDegreeDay.R

cumsum_rbR Documentation

cumsum_rb

Description

Compute the cumulative sum on a multilayered raster (rasterbrick), using indices spaning over specific time periods.

Usage

cumsum_rb(x, indices = NULL)

Arguments

x

rasterbrick object on which cumulative sum should be computed

indices

vector with indices over which the sum is to be cumulated.

Details

This function computes the cumulative sum over specific periods defined by the a vector of incides (e.g. two five-day cumulative sum c(1,1,1,1,1,2,2,2,2,2), restarting at zero on the first day of each series defined by the indices).

Author(s)

Reto Schmucki


RetoSchmucki/climateExtract documentation built on July 3, 2025, 11:39 p.m.