pyhctsa.operations.medical.pnn

pyhctsa.operations.medical.pnn(x)

Compute pNNx measures of heart rate variability (HRV).

The pNNx metrics quantify the proportion of successive RR intervals that differ by more than x milliseconds. This function assumes the input x is a time series of consecutive RR intervals in milliseconds.

This measure is commonly used in clinical HRV analysis. It is not appropriate to apply this method to z-scored or otherwise normalized time series, as meaningful interpretation depends on absolute differences in time.

This implementation is derived from HRVClassic, with the spectral measures removed, focusing solely on pNNx.

References

Parameters:
x : array-like

Time series of RR intervals in milliseconds (ms).

Returns:

Dictionary containing pNNx values, such as:

  • ’pNN20’: Percentage of successive differences > 20 ms

  • ’pNN50’: Percentage of successive differences > 50 ms

Return type:

dict