maad.util.skewness

maad.util.skewness(x, axis=None)[source]

Compute the skewness (asymetry) of an audio signal.

Parameters:
xndarray of floats

1d signal or 2d matrix

axisinteger, optional, default is None

select the axis to compute the kurtosis The default is to compute the mean of the flattened array.

Returns:
skfloat or ndarray of floats

skewness of x if x is a 1d vector => single value if x is a 2d matrix => array of values corresponding to the number of points in the other axis

Examples

>>> from maad import sound, util
>>> s, fs = sound.load('../data/spinetail.wav')
>>> util.skewness(s)
-0.006547980427883208