Skip to contents

Keep only the rows of data_source whose RoC is not NA, so that peaks can be detected and trends fitted from the remaining rows.

Usage

util_skip_na_roc(data_source, silent = FALSE)

Arguments

data_source

data.frame with a numeric column ROC, such as the output of estimate_roc().

silent

logical. If TRUE, do not warn about skipped rows (default = FALSE).

Value

data_source without the rows whose ROC is NA, with all columns and the order of the remaining rows unchanged. Without NA in ROC, data_source is returned unchanged. With silent = FALSE, a warning gives the number of skipped rows.

Details

The function stops with an error when ROC has no value other than NA, because no peak can then be detected.