Skip to contents

Applies rectification to EMG signals, converting all values to positive.

Usage

rectify(data, method = "full_wave")

Arguments

data

EMG signal. Can be a numeric vector (single channel), a matrix (T x M, time x channels), or a list of matrices.

method

Rectification method:

  • "full_wave": Take absolute value (default)

  • "half_wave": Set negative values to zero

Value

Rectified EMG signal.

Details

Rectification is a standard step in EMG processing that prepares the signal for envelope extraction. Full-wave rectification (absolute value) is most commonly used.

Examples

signal <- rnorm(1000)
rectified <- rectify(signal)  # full-wave rectification
half_rect <- rectify(signal, method = "half_wave")