Clip: Clip a Multi-channel Signal

ClipR Documentation

Clip a Multi-channel Signal

Description

This function clips the incoming (multi-channel) signal at the given limits. Specify empty values for either one of the limits if you don’t want clipping at that side of the signal range. Signal channels are represented by rows.

Usage

Clip(inSignal, inLowLimit = NULL, inHighLimit = NULL,
     inClipLowTo = NULL, inClipHighTo = NULL)

Arguments

inSignal

a matrix representing the (multi-channel) signal to be clipped.

inLowLimit

specifies the low level clipping value: values lower than this are replaced by either the limit itself or inClipLowTo. If empty or not specified, no clipping occurs.

inHighLimit

specifies the high level clipping value: values higher than this are replaced by either the limit itself or inClipHighTo. If empty or not specified, no clipping occurs.

inClipLowTo

if non-empty, this is a replacement value for too low values. If empty or not specified, inLowLimit is used.

inClipHighTo

if non-empty, this is a replacement value for too high values. If empty or not specified, inHighLimit is used.

Value

A matrix representing the clipped signal.

Author(s)

Marc Vidal (R version). Based on the original code from IPEM Toolbox.

Examples

s <- matrix(runif(64), ncol=8)
sc <- Clip(s, 0.5 ,0.7, 0, 1)

m-vidal/eaR documentation built on Nov. 18, 2022, 3:55 p.m.