process_flags: Process wear/non-wear flags for NHANES 2003-2004 and...

Description Usage Arguments Examples

View source: R/process_accel.R

Description

This function creates wear/non-wear flag matrices for processed NHANES 2003-2004 and 2005-2006 accelerometry data

Usage

1
2
process_flags(write = FALSE, local = FALSE, localpath = NULL,
  window = 90, tol = 2, tol.upper = 99, ...)

Arguments

write

logical argument indicating whether a .rda file of wear/non-wear flags should be created for each wave of processed data. Defaults to FALSE.

local

logical argument indicating whether the processed .rda accelerometry files are stored locally. If FALSE, will load them from the package data.

localpath

character string indicating where the locally processed .rda files are if you don't want to use those processed and included in the package.

window

size of the moving window used to assess non-wear in minutes. Defaults to 90 minutes. See accel.weartime for more details.

tol

maximum number of minutes with counts greater than 0 within the window allowed before a particular minute is considered "wear". That is, if for a given minute, the window around that minute has tol + 1 activity counts greater than 0, this miute is considered "wear". See accel.weartime for more details.

tol.upper

maximium activity count for any minute within the window Defaults to 99. That is, for a given minute, if the window contains any minutes with activity counts greater than tol.upper, this minute is considered "wear". See accel.weartime for more details.

...

aditional arguments to be passed to accel.weartime.

Examples

1
2
3
4
## Not run: 
process_accel(write=FALSE)

## End(Not run)

andrew-leroux/nhanesdata documentation built on April 23, 2018, 2:22 a.m.