# THIS FILE CONTAINS SAMPLE CODE FOR PROCESSING A SINGLE ACTIGRAPH FILE, OF THE
# FORMAT SHOWN IN `SAMPLE_FILE.CSV`
## Setup ####
rm(list = ls()) # clear memory
## Run the code ####
path_to_file <- "data-raw/ActiGraph/sample_code/sample_file.csv"
AG <- AGread::read_AG_counts(
file = path_to_file,
verbose = TRUE,
skip = 11
)
## For applying the Choi algorithm, see the function in the file
## `R/AG_Nonwear.R`
## Optional -- view the data ####
head(AG)
View(AG)
## Optional -- save the data ####
saveRDS(
AG, "data-raw/ActiGraph/sample_code/sample_output.rds"
)
## Read back in
#
# AG <- readRDS(
# "data-raw/ActiGraph/sample_code/sample_output.rds"
# )
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.