HRV - GoldenCheetah/GoldenCheetah GitHub Wiki

Starting with version 3.5 GoldenCheetah has facilities to deal with Heart Rate Variability (HRV) data, this includes:

  • HRV Measures at rest which can be generated by GoldenCheetah or imported from other applications s.t. HRV4Training, Elite HRV, etc.
  • HRV Processing capabilities to import R-R records, filter them and generate HRV metrics for recordings at rest or during activities.

This document is an introduction about how to use this facilities.

HRV Measures at rest

The HRV tab under Athlete Setting->Measures->Hrv allows to view and maintain HRV measures taken at rest and they can also be plotted on Metrics Trends charts. The following example available for download from the cloud, plots Recovery Points (a logarithm transform of rMSSD) and Rest HR together with a rolling average baseline:

Metrics Trends charts show metrics and formulas for activities so when there is no activity for the period (day/month/year depending on the grouping selected) no metric will be shown, if you want to chart measures for each day/week/month/year independent of activities there is a new Measures option in Curve Settings for v3.5.

For 3.6 to have a summery metrics use an overview chart. How to use it see: ChartTypes Trends->Overview

Here is an example of a tile in the Trend View

Tile with aggregate Metrics

{

# column names, if using metrics then best
# to use metricname() to get correct name for locale
# otherwise it won't translate to other languages
names {
    metricname(date,
         HRV_Recovery_Points ,
         Rest_AVNN ,
         Rest_HF ,
         Rest_LF ,
         Rest_PNN50,
         Rest_rMSSD,
         Rest_SDNN );
}

# column units, if using metrics then best
# to use metricunit() function to get correct string
# for locale and metric/imperial
units {
    metricunit(date,
         HRV_Recovery_Points ,
         Rest_AVNN ,
         Rest_HF ,
         Rest_LF ,
         Rest_PNN50,
         Rest_rMSSD,
         Rest_SDNN );
}

# values to display as doubles or strings
# if using metrics always best to use asstring()
# to convert correctly with dp, metric/imperial
# or specific formats eg. rowing pace xx/500m
values { 
    c(asaggstring (date),
         asaggstring(HRV_Recovery_Points) ,
         asaggstring(Rest_AVNN) ,
         asaggstring(Rest_HF) ,
         asaggstring(Rest_LF) ,
         asaggstring(Rest_PNN50),
         asaggstring(Rest_rMSSD),
         asaggstring(Rest_SDNN ));
} 

}

until version 3.5 - These HRV measures at rest are also available for display on Summary:

It also is possible to access daily measures (Body and Hrv for v3.5) from R charts and REST API, see the documentation in the corresponding section of the wiki.

Importing HRV measures at rest from other applications

HRV measures at rest can be imported from CSV files generated by applications such that HRV4Training, Elite HRV, etc. using Menu Bar->Share->Get Measures...->Hrv a popup window will appear where you can select the source:

The expected file format is documented here, if the origin is HRV4Training the exported file should import without changes, for other applications additional changes including column renaming may be necessary, the simplest way is to use a spreadsheet application for this transformation. Don't use quotation marks in comments, they are not supported and will provoke an import error.

Importing and Processing R-R data in GoldenCheetah

R-R data files can be imported from Garmin, Suunto and Polar devices in their native formats (FIT for Garmin, SML for Suunto and HRM for Polar) as standard activity files as explained in Import Activity Files.

For Garmin Edge devices (like this Edge 830 example), please activate "Log HRV" in Data Recording Settings:

txt files are also supported, the input text file can include RR interval values in one or two column format. That is, the RR interval values can be given as:
Type 1
0.759
0.690
0.702
0.712
0.773
Type 2
0.759 0.759
1.449 0.690
2.151 0.702
2.863 0.712
3.636 0.773
So in the second type of input, the first column includes the time indexes of R wave detections (zero time for the first detection) and second column the RR interval values. The RR interval values above are given in seconds, but millisecond values can also be given.

The information can be viewed in the Editor:

The data can also be accessed using the formula XDATA("HRV", "R-R", sparse) as User Data series in the Activity chart and Custom Metrics.

To plot only filtered R-R data (see below) in Activity chart the following formula can be used as User Data:

# R-R in ms replacing "bad" samples with last know good ones
{
    if (XDATA("HRV", "R-R?flag", sparse)=1) R_R <- XDATA("HRV", "R-R", sparse);
    R_R;
}

Additionally Standard HRV metrics based on R-R data s.t. rMSSD, Fraction of normal RR intervals, Average of all NN intervals, Standard deviation of NN and pNN5 to pNN50 are available as built in metrics. Spectral analysis metrics s.t. LF and HR are not implemented yet.

Filtering R-R data and generating HRV measures at rest

There is a tool to filter R-R data, accessible from the main menu: Menu BarEdit > Filter R-R Outliers

which implements standard filtering options for R-R data and allows to set HRV Measures at Rest, when this option is checked a new record will be added to HRV Measures with the date/time of the activity. This option should be used only when the data was taken in the recommended conditions for tracking recovery: first thing in the morning during 1 to 5 minutes at rest.

BACK: Special Topics: Overview
BACK: Table of contents