Learn R Programming

sits (version 1.1.0)

.sits_distances_sample: Sample a percentage of a time series distance matrix

Description

Takes a sits tibble with different labels and returns a new tibble. For a given field as a group criterion, this new table contains a given number or percentage of the total number of samples per group. Parameter n indicates the number of random samples with reposition. Parameter frac indicates a fraction of random samples without reposition. If frac > 1, no sampling is done.

Usage

.sits_distances_sample(distances, frac)

Value

Data.table with a fixed quantity of samples of informed labels and all other.

Arguments

distances

Distances associated to a time series.

frac

Percentage of samples to pick.

Author

Rolf Simoes, rolf.simoes@inpe.br