apply_youth_sojourn: Apply the youth Sojourn method

View source: R/youth_apply_sojourn.R

apply_youth_sojournR Documentation

Apply the youth Sojourn method

Description

Function for using the youth Sojourn method developed by Hibbing et al. (2018)

Usage

apply_youth_sojourn(
  AG,
  vm = c("Vector.Magnitude", "ENMO"),
  Site = c("Hip", "Wrist"),
  demo_interactive = FALSE,
  verbose = FALSE,
  ...
)

Arguments

AG

a data frame of monitor and demographic data

vm

the variable to use for processing, either "Vector.Magnitude" (for activity counts) or "ENMO" (for raw acceleration)

Site

the wear location of the monitor, either "Hip" or "Wrist"

demo_interactive

logical. Input demographics interactively if missing variables are identified during format checking?

verbose

logical. Print processing updates to the console?

...

Further arguments passed to youth_name_test

Value

The original data frame, plus additional predictions made by the Sojourn method

Note

The functions AGread::read_AG_counts and AGread::read_AG_raw are recommended for assembling the monitor-specific portion of the AG data frame.

Examples

data(example_data, package = "Sojourn")

  results_youth_soj <- apply_youth_sojourn(
    AG = example_data,
    vm = "Vector.Magnitude",
    Site = "Hip"
  )
  utils::head(results_youth_soj)


Sojourn documentation built on Nov. 20, 2025, 1:07 a.m.