clean_marker_channel: Clean the marker channel of an fEMG recording

Description Usage Arguments Value Examples

View source: R/clean_marker_channel.R

Description

Clean the marker channel of an fEMG recording

Usage

1
2
3
4
5
6
7
clean_marker_channel(
  femg_data,
  marker_channel,
  valid_marker_values,
  invalid_marker_values = c(),
  denoise_width = "auto"
)

Arguments

femg_data

data frame or tibble

marker_channel

the name of the column in femg_data that corresponds to the marker channel

valid_marker_values

valid marker values to be found in marker_channel that are used to indicate the stimulus/task

invalid_marker_values

invalid marker values that can safely be set to 0/off

denoise_width

an integer or "auto". The number of samples for which to take the median as a method to remove individual samples with unexpected values.

Value

femg_data with additional column (marker_channel)_cleaned

Examples

1
2
3
4
5
clean_marker_channel(
    femg_raw_data_sample,
    marker_channel = "Marker",
    valid_marker_values = c(54)
    )

SDAMcIntyre/countenance documentation built on Dec. 18, 2021, 11:58 a.m.