Package 'actilifecounts'

Title: Generate Activity Counts from Raw Accelerometer Data
Description: A tool to obtain activity counts, originally a translation of the 'python' package 'agcounts' <https://github.com/actigraph/agcounts>. This tool allows the processing of data from any accelerometer brand, with a more flexible approach to handle different sampling frequencies.
Authors: Jairo Hidalgo Migueles
Maintainer: Jairo Hidalgo Migueles <[email protected]>
License: LGPL (>= 3)
Version: 1.1.1
Built: 2024-11-02 03:42:17 UTC
Source: https://github.com/jhmigueles/actilifecounts

Help Index


bpf_filter

Description

Bandpass filter for actigraph downsampled data

Usage

bpf_filter(downsample_data = c(), verbose = FALSE)

Arguments

downsample_data

Matrix containing downsampled data

verbose

Print diagnostic messages

Value

The filtered data

Author(s)

Jairo Hidalgo Migueles

References

Ali Neishabouri et al. DOI: https://doi.org/10.21203/rs.3.rs-1370418/v1


get_counts

Description

get_counts

Usage

get_counts(raw, sf, epoch, lfe_select = FALSE, verbose = FALSE)

Arguments

raw

Matrix containing raw data (3 columns, no timestamp should be included)

sf

Sample frequency of raw data (Hz)

epoch

Epoch length to aggregate activity counts

lfe_select

False for regular trimming, True for allow more noise

verbose

Print diagnostic messages

Value

Matrix containing the count values per epoch in each axis and vector magnitude

Author(s)

Jairo Hidalgo Migueles

References

Ali Neishabouri et al. DOI: https://doi.org/10.21203/rs.3.rs-1370418/v1


resample_10hz

Description

Get data back to 10 Hz for accumulation

Usage

resample_10hz(trim_data = c(), verbose = FALSE)

Arguments

trim_data

Matrix containing the trimmed/thresholded data

verbose

Print diagnostic messages

Value

Resampled data

Author(s)

Jairo Hidalgo Migueles

References

Ali Neishabouri et al. DOI: https://doi.org/10.21203/rs.3.rs-1370418/v1


resample_30hz

Description

Resample the raw data.

Usage

resample_30hz(raw = c(), sf = 30, verbose = FALSE)

Arguments

raw

Matrix containing raw data

sf

Sample frequency of raw data (Hz)

verbose

Print diagnostic messages

Value

resampled_data

Author(s)

Jairo Hidalgo Migueles

References

Ali Neishabouri et al. DOI: https://doi.org/10.21203/rs.3.rs-1370418/v1


sum_counts

Description

Generate counts per epoch.

Usage

sum_counts(downsample_10hz, epoch = 60, verbose = FALSE)

Arguments

downsample_10hz

Matrix containing downsampled to 10hz data

epoch

Used to compute how many raw samples are used for computing an epoch

verbose

Used to compute how many raw samples are used for computing an epoch

Value

Matrix with counts per epoch in the 3 axes

Author(s)

Jairo Hidalgo Migueles

References

Ali Neishabouri et al. DOI: https://doi.org/10.21203/rs.3.rs-1370418/v1


trim_data

Description

trim_data

Usage

trim_data(bpf_data = c(), lfe_select = FALSE, verbose = FALSE)

Arguments

bpf_data

Matrix containing filtered data

lfe_select

False for regular trimming, True for allow more noise

verbose

Print diagnostic messages

Value

The trimmed/thresholded data

Author(s)

Jairo Hidalgo Migueles

References

Ali Neishabouri et al. DOI: https://doi.org/10.21203/rs.3.rs-1370418/v1