CalculateSpectrogram function

Calculates the spectrogram of a signal

Calculates the spectrogram of a signal

Calculates the spectrogram of the heart rate signal after filtering and interpolation in a window of a certain size

CalculateSpectrogram(HRVData, size, shift, sizesp = 1024, verbose=NULL)

Arguments

  • HRVData: Data structure that stores the beats register and information related to it
  • size: Size of window for calculating spectrogram (seconds)
  • shift: Displacement of window for calculating spectrogram (seconds)
  • sizesp: Points for calculating spectrogram (zero padding)
  • verbose: Deprecated argument maintained for compatibility, use SetVerbose() instead

Returns

Returns the spectrogram of the heart rate signal

References

L. Rodriguez-Linares, A. Mendez, M. Lado, D. Olivieri, X. Vila, I. Gomez-Conde, "An open source tool for heart rate variability spectral analysis", Computer Methods and Programs in Biomedicine 103, 39-50, doi:10.1016/j.cmpb.2010.05.012 (2011)

Author(s)

M. Lado, A. Mendez, D. Olivieri, L. Rodriguez, X. Vila

Note

An example including all the necessary steps to obtain the spectrogram

of a wfdb register is giving below:

##Reading a wfdb register and storing into a data structure:

md = CreateHRVData(Verbose = TRUE)

md = LoadBeatWFDB(md, RecordName = "register_name",

RecordPath = "register_path", verbose = TRUE)

##Calculating heart rate signal:

md = BuildNIHR(md)

##Filtering heart rate signal:

md = FilterNIHR(md)

##Interpolating heart rate signal:

md = InterpolateNIHR(md)

##Calculating spectrogram:

CalculateSpectrogram(md, size = 120, shift = 10, sizesp = 1024)