ntsa.tools.statistics
At a glance
| Function | One-liner |
|---|---|
fun_PSD(dt, X) |
Power spectral density of one or more signals: (f, PSD). |
autocorrelation(x, n_lags) |
Normalized ACF, acf[0]=1. |
signal_stats(x, dt, n_bins=64) |
Dict of moments, PSD, PDF and ACF. |
Full reference
ntsa.tools.statistics
Signal statistics: power spectral density, autocorrelation, summary moments.
fun_PSD(dt, X)
Compute the Power Spectral Density of one or more signals.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
dt
|
float
|
Sampling time. |
required |
X
|
ndarray
|
Signal(s), shape |
required |
Returns:
| Name | Type | Description |
|---|---|---|
f |
ndarray
|
Frequencies, shape |
PSD |
list of np.ndarray
|
Power Spectral Density of each row of |
Source code in ntsa/tools/statistics.py
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 | |
autocorrelation(x, n_lags)
Normalized autocorrelation for lags 0..n_lags; acf[0] = 1.
Source code in ntsa/tools/statistics.py
44 45 46 47 48 49 | |
signal_stats(x, dt, n_bins=64)
Summary statistics of a scalar series.
Returns:
| Type | Description |
|---|---|
dict with keys: mean, std, skew, kurtosis, f, psd, pdf_centers, pdf, acf, acf_lags.
|
|
Source code in ntsa/tools/statistics.py
52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 | |