[ top | up ]

Tachometer RR->HR

Syntax

[ntimes,nvals,nlabels] = hrtach(starttime,rrintervals,labels,
                                                      sr,goodlabel);

Arguments

starttime The time stamp of the first RR interval occurred. This is used only to set the timestamps of the tachometer output.
rrintervals A column vector of RR intervals, in seconds.
labels A column vector giving a label for each RR interval, marking it as valid or invalid.
sr Desired sampling rate (samples/second) of the tachometer output. Default: 4
goodlabel The numerical code corresponding to valid data. Default: 1

Returned Values

ntimes The time stamps of each of the tachometer samples
nvals The values of "instantaneous heart rate," according to the Berger algorithm.
nlabels Labels indicating the validity/invalidity of each tachometer data point. A point is marked as valid only if all of the RR intervals that were involved in the calculation of that data point are valid.

Description

Translates RR intervals (seconds) into heart rate (beats/minute) evenly sampled in time. This is done using the method proposed by Berger: a continuous signal is constructed that is piecewise constant and whose value during any RR interval is 60/rr. This continuous signal is anti-alias filtered using a boxcar of width twice the interval between samples, and then sampled, producing the output.

The algorithm is specifically intended for translating RR intervals into a signal with "nice" properties for spectral analysis. (In the Berger paper, "nice" means that the tachometer output has a form close to that of the hypothetical input to the integrate-and-fire system which could have produced the RR interval sequence.

If you seek simply to translate an unevenly sampled signal into an evenly sampled one, see spline.

References

RD Berger et al., "An efficient algorithm for spectral analysis of heart rate variability" IEEE Trans. Biomed. Eng. 1986:33:900-904

See Also

spline

Examples