compute_subset_range: Compute the indices corresponding to a defined subset

Description Usage Arguments Value Examples

View source: R/utils-subsetting-time-series.R

Description

Compute the indices corresponding to a defined subset

Usage

1

Arguments

bounds

the vector with lower and upper bound, expressed as numeric fractions of the time series in [0, 1]

n

the totla length of the vector to subset

Value

the indices corresponding to the subset defined by bounds on a vector of length n

Examples

1
2
compute_subset_range(c(0, 0.5), 10) # 1:5
compute_subset_range(c(0.5, 1), 10) # 6:10

weecology/MATSS-forecasting documentation built on Nov. 28, 2020, 10:19 a.m.