tbr_sum_window: Sum Based on a Time-Window

View source: R/tbr_sum.R

tbr_sum_windowR Documentation

Sum Based on a Time-Window

Description

Sum Based on a Time-Window

Usage

tbr_sum_window(x, tcolumn, unit = "years", n, i, na.rm, na.pad)

Arguments

x

column containing the values to calculate the sum.

tcolumn

formatted time column.

unit

character, one of "years", "months", "weeks", "days", "hours", "minutes", "seconds"

n

numeric, describing the length of the time window.

i

row

na.rm

logical. Should missing values be removed?

na.pad

logical if 'na.pad = TRUE' incomplete windows (duration of the window < 'n') return 'NA'.

Value

numeric value


tbrf documentation built on Aug. 21, 2025, 6:04 p.m.