devctrl.data.transforms#

Module attributes

log

REGISTERING TRANSFORMS Transforms can be registered using the decorator _register_transform.

Functions

apply_to_columns

Apply a transform to all selected columns.

derivative

Calculate the n-th derivative of column(s) <key> numerically. :param n: The derivative to calculate :param pre_func: A function taking and returning a 1d numpy array. If given, it is applied before every derivative. This may, for example, be useful if the data should be smoothened before taking the derivatives.

downsample_log

export_functions

Create new versions of all registered functions with new default arguments override_kwargs

get_data_normalize_scale

Return the scale factor that data must be multiplied with to be entirely within the interval [-1, 1]

integrate

Numerically integrate the data of column(s) <key> n times

normalize

Normalize all columns except skipcols so that the largest absolute value becomes either 1 or -1.

normalize_data

Return data scaled to be within [-1, 1]

normalize_to

Normalize the data so that for each column, the value at x or the mean value of the range x-dx,x+dx is set to (-)1.

notch

Notch filter at frequency w0 with quality factor Q.

remove_nans

Delete all rows where any number is nan

scale

Multiply data by factor

shift

Add shift to data

shift_to_zero

Shift data so that either the min or max value is zero

smoothen