collapse_gt3x: Collapse data that were read using 'read_gt3x'

Description Usage Arguments Value Examples

View source: R/collapse_gt3x.R

Description

Collapse data that were read using read_gt3x

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
collapse_gt3x(AG, filename = "gt3x file", output_window_secs = 1,
  filter = TRUE, filter_hz = 35, verbose = FALSE, ...)

## S3 method for class 'RAW'
collapse_gt3x(AG, filename = "gt3x file",
  output_window_secs = 1, filter = TRUE, filter_hz = 35,
  verbose = FALSE, method = c("legacy", "expanded"), ...)

## S3 method for class 'IMU'
collapse_gt3x(AG, filename = "gt3x file",
  output_window_secs = 1, filter = TRUE, filter_hz = 35,
  verbose = FALSE, method = c("legacy", "expanded"), ...)

Arguments

AG

The object to collapse, inheriting from class "RAW" or "IMU"

filename

character. Filename to associate with the data.

output_window_secs

the desired epoch length; defaults to one second

filter

a logical scalar: Apply a low-pass filter to gyroscope data?

filter_hz

The cutoff for the low-pass filter

verbose

A logical scalar: Print processing updates?

...

Additional arguments. Currently unused.

method

the collapsing method to use

Value

A data frame of collapsed data

Examples

1
2
3
4
5
6
7
8
file <- system.file(
  "extdata",
  "example.gt3x",
  package = "AGread"
)
data <- read_gt3x(file)
head(collapse_gt3x(data$RAW))
head(collapse_gt3x(data$IMU))

AGread documentation built on Feb. 26, 2020, 5:12 p.m.