Learn R Programming

TwoRegression (version 1.1.1)

smooth_2rm: Smooth two-regression estimates over specified periods

Description

Smooth two-regression estimates over specified periods

Usage

smooth_2rm(AG, time_var = "Timestamp", unit = "60 sec", verbose = FALSE, ...)

Value

Smoothed data, collapsed in the specified intervals

Arguments

AG

data frame of ActiGraph data

time_var

character scalar. Name of the timestamp variable (required to verify that input epoch length is 10 seconds)

unit

the interval to use for smoothing (see floor_date). Default is "60 sec"

verbose

logical. Print updates to console?

...

currently unused

Examples

Run this code

data(all_data, package = "TwoRegression")

  result <- TwoRegression(
    all_data, "Hibbing 2018", gyro_var = "Gyroscope_VM_DegPerS",
    direction_var = "mean_magnetometer_direction",
    site = c("Left Ankle", "Right Ankle"), algorithm = 1:2
  )

  smooth_2rm(result)

Run the code above in your browser using DataLab