1.6.1 Module description

Statistics Functions for dspic33-cmsis-dsp Library.

This group of functions provides the APIs for statistical analysis functions in the dspic33-cmsis-dsp Library.

It includes functions for single-precision floating-point and Q31 fixed-point data types, supporting functionalities like computing mean, maximum, minimum, sum of squares (power), variance, and standard deviation.

Features:
  • Mean value calculation

  • Maximum and minimum value detection (with index)

  • Sum of squares (power) computation

  • Variance and standard deviation calculation

Usage Example:
float32_t data[SIZE], mean, max, min, power, var, std;
uint32_t maxIdx, minIdx;
mchp_mean_f32(data, SIZE, &mean);
mchp_max_f32(data, SIZE, &max, &maxIdx);
mchp_min_f32(data, SIZE, &min, &minIdx);
mchp_power_f32(data, SIZE, &power);
mchp_var_f32(data, SIZE, &var);
mchp_std_f32(data, SIZE, &std);