Function to calculate HRV (heart rate variability) from ECG signal data.
Uses biosppy to get the indices of the R peaks in the ECG signal.
https://biosppy.readthedocs.io/en/stable/
HRV is calculated using the Root Mean Square of Successive Differences (RMSSD).
https://www.ahajournals.org/doi/full/10.1161/01.cir.93.5.1043