Creates a new column, named wear
, in the impactr_data
object
provided by data
indicating its classification of wear or non-wear
time.
Arguments
- data
An
impactr_data
object, as obtained with read_acc().- nonwear_stage1, nonwear_stage2
A numeric vector containing the binary non-wear classification (0 is wear and 1 is non-wear) of each algorithm's stage per
window2
blocks as obtained with thedetect_nonwear()
function.- window2
Window 2 size, in minutes, for the non-wear detection algorithm. Must be the same value as used by the
detect_nonwear()
function.
Value
The impactr_data
object provided by data
with a new
column named wear
with the binary wear classification (0 is non-wear and
1 is wear) per sample. Notice that this binary classification is regarding
the wear time NOT non-wear.
Details
This is an internal function, designed to be used inside the wrapper function remove_nonwear() that integrates all steps of detection, removal and inspection of accelerometer non-wear time.