Title: | Heart Rate Turbulence Analysis |
---|---|
Description: | Methods to scan RR interval data for Premature Ventricular Complexes (PVCs) and parameterise and plot the resulting Heart Rate Turbulence (HRT). The methodology of HRT analysis is based on the original publication by Schmidt et al. <doi:10.1016/S0140-6736(98)08428-1> and extended with suggestions from <doi:10.1088/1361-6579/ab98b3>. |
Authors: | Valeria Blesius [aut, cre] |
Maintainer: | Valeria Blesius <[email protected]> |
License: | GPL-2 |
Version: | 1.1 |
Built: | 2025-03-12 06:00:43 UTC |
Source: | https://github.com/vblesius/rhrt |
This class extends the HRT class. An avHRT is the average of an HRTList and saves the way in which it was calculated.
## S4 method for signature 'avHRT' initialize( .Object, av = mean, orTO = "avAfter", orTS = "avBefore", pTO = NA_real_, pTS = NA_real_, pTT = NA_real_, pnTS = NA_real_, nRMSSD = NA_real_, couplRR = NA_real_, compRR = NA_real_, preRRs = NA_real_, postRRs = NA_real_ )
## S4 method for signature 'avHRT' initialize( .Object, av = mean, orTO = "avAfter", orTS = "avBefore", pTO = NA_real_, pTS = NA_real_, pTT = NA_real_, pnTS = NA_real_, nRMSSD = NA_real_, couplRR = NA_real_, compRR = NA_real_, preRRs = NA_real_, postRRs = NA_real_ )
.Object |
The name of the class |
av |
(Function) Type of averaging, either mean or median |
orTO |
(Character) Order in which TO was calculated, either "avAfter" (assessment of parameter and averaging) or "avBefore" (averaging of the VPCSs and assessment of parameter) |
orTS |
(Character) Order in which TS was calculated, either "avAfter" (assessment of parameter and averaging) or "avBefore" (averaging of the VPCSs and assessment of parameter) |
pTO |
(Numeric) p-value of t-test checking the validity of TO |
pTS |
(Numeric) p-value of t-test checking the validity of TS |
pTT |
(Numeric) p-value of t-test checking the validity of TT |
pnTS |
(Numeric) p-value of t-test checking the validity of normalised TS |
nRMSSD |
(Numeric) RMSSD normalised to HR |
couplRR |
(Numeric) Coupling interval |
compRR |
(Numeric) Compensatory interval |
preRRs |
(Numeric vector) Preceding intervals |
postRRs |
(Numeric vector) Following intervals |
(avHRT) A new avHRT object
av
(Function) Type of averaging, either mean or median
orTO
(Character) Order in which TO was calculated, either "avAfter" (assessment of parameter and averaging) or "avBefore" (averaging of the VPCSs and assessment of parameter)
orTS
(Character) Order in which TS was calculated, either "avAfter" (assessment of parameter and averaging) or "avBefore" (averaging of the VPCSs and assessment of parameter)
pTO
(Numeric) p-value of t-test checking the validity of TO
pTS
(Numeric) p-value of t-test checking the validity of TS
pTT
(Numeric) p-value of t-test checking the validity of TT
pnTS
(Numeric) p-value of t-test checking the validity of normalised TS
nRMSSD
(Numeric) RMSSD normalised to HR
For each index the average of the intervals across all HRTs in the HRTList is calculated and the averaged HRT returned. The type of averaging, the order of HRT parameter assessment and interval lengths for normalising TS can be passed.
calcAvHRT( HRTListObj, av = mean, orTO = "avAfter", orTS = "avBefore", IL = HRTListObj@IL, normIL = c_normIL, normHallstrom = TRUE, coTO = COTO, coTS = COTS, coTT = COTT ) ## S4 method for signature 'HRTList' calcAvHRT( HRTListObj, av = mean, orTO = "avAfter", orTS = "avBefore", IL = HRTListObj@IL, normIL = c_normIL, normHallstrom = TRUE, coTO = COTO, coTS = COTS, coTT = COTT )
calcAvHRT( HRTListObj, av = mean, orTO = "avAfter", orTS = "avBefore", IL = HRTListObj@IL, normIL = c_normIL, normHallstrom = TRUE, coTO = COTO, coTS = COTS, coTT = COTT ) ## S4 method for signature 'HRTList' calcAvHRT( HRTListObj, av = mean, orTO = "avAfter", orTS = "avBefore", IL = HRTListObj@IL, normIL = c_normIL, normHallstrom = TRUE, coTO = COTO, coTS = COTS, coTT = COTT )
HRTListObj |
HRTList object |
av |
(Function) Type of averaging the VPCSs, either mean or median |
orTO |
(Character) Order in which TO was calculated, either "avAfter" (assessment of parameter and averaging) or "avBefore" (averaging of the VPCSs and assessment of parameter) |
orTS |
(Character) Order in which TS was calculated, either "avAfter" (assessment of parameter and averaging) or "avBefore" (averaging of the VPCSs and assessment of parameter) |
IL |
(Numeric) The overall arithmetic mean of the interval length of the measurement to normalise TS |
normIL |
(Numeric) The interval length to which TS should be normalised |
normHallstrom |
(Boolean) Should the normalisation of Hallstrom be used? |
coTO |
(Numeric) Cut-off value for TO |
coTS |
(Numeric) Cut-off value for TS and nTS |
coTT |
(Numeric) Cut-off value for TT |
To eliminate other RR variability TS is commonly assessed after averaging the VPCSs. TO is commonly first calculated from the single VPCS and then averaged. (See 'Heart Rate Turbulence: Standards of Measurement, Physiological Interpretation, and Clinical Use, Axel Bauer et al., Journal of the American College of Cardiology, Volume 52, Issue 17, Pages 1353-1365')
(avHRT) The avHRT object of the given HRTList
# You need an HRTList hrtl <- vectorToHRT(testdataLong, testdataLong_Ann) # Recalculate the avHRT with different normalisation calcAvHRT(hrtl, normIL = 1000, normHallstrom = FALSE) # Recalculate the avHRT based on a different calculation order calcAvHRT(hrtl, orTO = "avBefore", orTS = "avAfter") # Set custom parameter cut-offs for the reliability check ## You should keep in mind to give the same cut-offs when calling getResults() calcAvHRT(hrtl, coTO = 0.022, coTS = 1.42, coTT = 12)
# You need an HRTList hrtl <- vectorToHRT(testdataLong, testdataLong_Ann) # Recalculate the avHRT with different normalisation calcAvHRT(hrtl, normIL = 1000, normHallstrom = FALSE) # Recalculate the avHRT based on a different calculation order calcAvHRT(hrtl, orTO = "avBefore", orTS = "avAfter") # Set custom parameter cut-offs for the reliability check ## You should keep in mind to give the same cut-offs when calling getResults() calcAvHRT(hrtl, coTO = 0.022, coTS = 1.42, coTT = 12)
Calculates all HRT parameters needed for an HRT object and saves them in the corresponding slots.
calcHRTParams(HRTObj, IL = c_normIL, normIL = c_normIL) ## S4 method for signature 'HRT' calcHRTParams(HRTObj, IL = c_normIL, normIL = c_normIL)
calcHRTParams(HRTObj, IL = c_normIL, normIL = c_normIL) ## S4 method for signature 'HRT' calcHRTParams(HRTObj, IL = c_normIL, normIL = c_normIL)
HRTObj |
(HRT) The HRT object of which the parameters should be calculated |
IL |
(Numeric) The overall arithmetic mean of the interval length of the measurement to normalise TS |
normIL |
(Numeric) The interval length to which TS should be normalised |
This method is a wrapper for the methods calcTO and calcTS.
(HRT) An HRT object with (re)calculated HRT parameters
Calculates the TO parameters and saves it in the corresponding slot
calcTO(HRTObj) ## S4 method for signature 'HRT' calcTO(HRTObj)
calcTO(HRTObj) ## S4 method for signature 'HRT' calcTO(HRTObj)
HRTObj |
(HRT) The HRT object, for which TO should be calculated |
(HRT) An HRT object with (re)calculated TO
Calculates all TS parameters (TS itself, its index TT (turbulence timing) and the intercept for the plot) and saves them in the corresponding slots. Can also calculate normalised TS and intercept.
calcTS(HRTObj, normalising = FALSE, IL = c_normIL, normIL = c_normIL) ## S4 method for signature 'HRT' calcTS(HRTObj, normalising = FALSE, IL = c_normIL, normIL = c_normIL)
calcTS(HRTObj, normalising = FALSE, IL = c_normIL, normIL = c_normIL) ## S4 method for signature 'HRT' calcTS(HRTObj, normalising = FALSE, IL = c_normIL, normIL = c_normIL)
HRTObj |
(HRT) The HRT object, for which TS should be calculated |
normalising |
(Boolean) Should the normalised TS be calculated? |
IL |
(Numeric) The overall arithmetic mean of the interval length of the measurement to normalise TS |
normIL |
(Numeric) The interval length to which TS should be normalised |
(HRT) An HRT object with (re)calculated TS+intercept or nTS+nintercept
Checks annotations for compatibility
checkAnnotations(annotations, input, PVCAnn, label)
checkAnnotations(annotations, input, PVCAnn, label)
annotations |
(Character vector) Annotations matching input |
input |
(Numeric vector) RR intervals in ms |
PVCAnn |
(Character) Character that marks a VPC in the annotations |
label |
(Character) Name of the data given and formatted for output |
No return value, possibly throws errors/warnings
Checks RR-intervals for HRT criteria and returns an HRT object
checkForHRT(intervals, numPreRRs = c_numPreRRs, numPostRRs = c_numPostRRs)
checkForHRT(intervals, numPreRRs = c_numPreRRs, numPostRRs = c_numPostRRs)
intervals |
(Numeric vector) RR intervals in ms |
numPreRRs |
(Numeric) Number of RRs before the coupling interval that are used for filtering |
numPostRRs |
(Numeric) Number of RRs after the compensatory interval that are used for filtering |
(HRT) A single HRT object or NULL
Checks data input for compatibility
checkInput(input, numSnippet, label)
checkInput(input, numSnippet, label)
input |
(Numeric vector) RR intervals in ms |
numSnippet |
(Numeric) number of RRs in the the HRT snippet |
label |
(Character) Name of the data given and formatted for output |
No return value, possibly throws errors/warnings
Checks whether slots are set
Check for HRTList class
checkValidity(x, ...) ## S4 method for signature 'HRT' checkValidity(x) ## S4 method for signature 'HRTList' checkValidity(x, av = FALSE, pos = FALSE)
checkValidity(x, ...) ## S4 method for signature 'HRT' checkValidity(x) ## S4 method for signature 'HRTList' checkValidity(x, av = FALSE, pos = FALSE)
x |
HRTList |
... |
Other parameters |
av |
(Boolean) Should avHRT be checked? |
pos |
(Boolean) Should pos be checked? |
No return value, possibly throws errors/warnings
No return value, possibly throws errors
Cleans data input for further checks or calculation
cleanInput(input)
cleanInput(input)
input |
(Numeric vector) RR intervals in ms |
(numeric vector) Input vector without possible bias
Extracts all values of the given slot in each HRT of the HRTList and returns them in a list
getHRTParams(HRTListObj, sl) ## S4 method for signature 'HRTList' getHRTParams(HRTListObj, sl)
getHRTParams(HRTListObj, sl) ## S4 method for signature 'HRTList' getHRTParams(HRTListObj, sl)
HRTListObj |
HRTList object |
sl |
(Character) Value of a slot saved by an HRT object |
(numeric vector or list) Vector or list of the numerics stored in the given slot
# You need an HRTList hrtl <- vectorToHRT(testdataLong, testdataLong_Ann) # Get all TOs of the HRTs in your HRTList getHRTParams(hrtl, "TO") # You can access all slots in the HRTs getHRTParams(hrtl, "intercept") # If you access slots that include more than one numeric, the function returns a list getHRTParams(hrtl, "preRRs")
# You need an HRTList hrtl <- vectorToHRT(testdataLong, testdataLong_Ann) # Get all TOs of the HRTs in your HRTList getHRTParams(hrtl, "TO") # You can access all slots in the HRTs getHRTParams(hrtl, "intercept") # If you access slots that include more than one numeric, the function returns a list getHRTParams(hrtl, "preRRs")
Scans for HRTs in the given vector and returns an HRTList object.
getHRTs( intervals, annotations = NULL, PVCAnn = "V", numPreRRs = c_numPreRRs, numPostRRs = c_numPostRRs, numSnippet )
getHRTs( intervals, annotations = NULL, PVCAnn = "V", numPreRRs = c_numPreRRs, numPostRRs = c_numPostRRs, numSnippet )
intervals |
(Numeric vector) RR intervals in ms |
annotations |
(Character vector) Annotations matching input |
PVCAnn |
(Character) Character that marks a VPC in the annotations |
numPreRRs |
(Numeric) Number of RRs before the coupling interval that are used for filtering |
numPostRRs |
(Numeric) Number of RRs after the compensatory interval that are used for filtering |
numSnippet |
(Numeric) Number of RRs in the HRT snippet |
(HRTList) HRTList with only pos and HRTs set
Returns the positions of all ventricular premature complexes (VPCs) and accordingly the coupling intervals that were found in the given vector when the HRTList was created.
getPositions(HRTListObj) ## S4 method for signature 'HRTList' getPositions(HRTListObj)
getPositions(HRTListObj) ## S4 method for signature 'HRTList' getPositions(HRTListObj)
HRTListObj |
(HRTList object) |
No return value, possibly throws errors/warnings
Returns the HRT parameters of the HRTList. Turbulence onset is calculated for each HRT object and then averaged, turbulence slope is calculated via averaging the intervals of all HRT objects to one HRT object and then estimating the maximal slope.
getResults( HRTListObj, type = "class", TT = FALSE, nTS = FALSE, safe = TRUE, pmax = 0.05, num = FALSE, coTO = COTO, coTS = COTS, coTT = COTT ) ## S4 method for signature 'HRTList' getResults( HRTListObj, type = "class", TT = FALSE, nTS = FALSE, safe = TRUE, pmax = 0.05, num = FALSE, coTO = COTO, coTS = COTS, coTT = COTT )
getResults( HRTListObj, type = "class", TT = FALSE, nTS = FALSE, safe = TRUE, pmax = 0.05, num = FALSE, coTO = COTO, coTS = COTS, coTT = COTT ) ## S4 method for signature 'HRTList' getResults( HRTListObj, type = "class", TT = FALSE, nTS = FALSE, safe = TRUE, pmax = 0.05, num = FALSE, coTO = COTO, coTS = COTS, coTT = COTT )
HRTListObj |
HRTList object |
type |
(String) Determining the amount of output: 'class' gives the HRT class, 'parameter' the parameter values and 'full' additionally the p-values describing parameter reliability |
TT |
(Boolean) Should TT be given? |
nTS |
(Boolean) Should the normalised TS (nTS) be given or used for the determination of the HRT class? |
safe |
(Boolean) Should all values be given regardless of reliability checks? Note, that 'safe' is ignored when the type is 'full'. |
pmax |
(Numeric) The significance level |
num |
(Boolean) Should the results be numeric? This forces the results to stay numeric, but sets not reliable values as NA, if 'safe' is TRUE. Forced numeric values cannot be combined with type 'class'. |
coTO |
(Numeric) Cut-off value for TO |
coTS |
(Numeric) Cut-off value for TS and nTS |
coTT |
(Numeric) Cut-off value for TT |
(Named vector, character or numeric) Either HRT classes, HRT parameter values and/or p-values
# You need an HRTList hrtl <- vectorToHRT(testdataLong, testdataLong_Ann) # Get the HRT classes of your HRTList getResults(hrtl) getResults(hrtl, TT = TRUE) # Get the HRT parameter values of your HRTList getResults(hrtl, type = "parameter", TT = TRUE)
# You need an HRTList hrtl <- vectorToHRT(testdataLong, testdataLong_Ann) # Get the HRT classes of your HRTList getResults(hrtl) getResults(hrtl, TT = TRUE) # Get the HRT parameter values of your HRTList getResults(hrtl, type = "parameter", TT = TRUE)
Returns the VPCS intervals in right order
getRRs(HRTObj) ## S4 method for signature 'HRT' getRRs(HRTObj)
getRRs(HRTObj) ## S4 method for signature 'HRT' getRRs(HRTObj)
HRTObj |
HRT |
(numeric vector) All VPCS intervals
This class specifies an object to save the lengths of intervals surrounding a premature ventricular beat. It saves the HRT parameters turbulence onset (TO), slope (TS) and timing (TT) after calculation as well as the coefficients of an ab-line used for the plot. TS is saved after common calculation and after normalising.
## S4 method for signature 'HRT' initialize( .Object, couplRR = NA_real_, compRR = NA_real_, preRRs = NA_real_, postRRs = NA_real_ )
## S4 method for signature 'HRT' initialize( .Object, couplRR = NA_real_, compRR = NA_real_, preRRs = NA_real_, postRRs = NA_real_ )
.Object |
(Character) The name of the class |
couplRR |
(Numeric) Coupling interval |
compRR |
(Numeric) Compensatory interval |
preRRs |
(Numeric vector) Preceding intervals |
postRRs |
(Numeric vector) Following intervals |
(HRT) A new HRT object
couplRR
(Numeric) Coupling interval
compRR
(Numeric) Compensatory interval
preRRs
(Numeric vector) Preceding intervals
postRRs
(Numeric vector) Following intervals
TO
(Numeric) Turbulence onset
TS
(Numeric) Turbulence slope
TT
(Numeric) Turbulence timing
intercept
(Numeric) Intercept of regression line of TS
nTS
(Numeric) Normalised Turbulence slope
nintercept
(Numeric) Intercept of regression line of nTS
This class specifies an object to save all HRT objects of a given vector. It also saves an averaged HRT for calculation of the averaged HRT parameters and plotting of all HRTs in a single plot.
## S4 method for signature 'HRTList' initialize( .Object, name = NA_character_, IL = NA_real_, pos = NA_real_, HRTs = list(), avHRT = new("avHRT"), RMSSD = NA_real_ )
## S4 method for signature 'HRTList' initialize( .Object, name = NA_character_, IL = NA_real_, pos = NA_real_, HRTs = list(), avHRT = new("avHRT"), RMSSD = NA_real_ )
.Object |
(Character) The name of the class |
name |
(Character) Name of the vector if given |
IL |
(Numeric) Arithmetic mean of the overall interval length of the vector |
pos |
(Numeric vector) Positions of premature ventricular complexes in given input |
HRTs |
(List) All HRT objects |
avHRT |
(avHRT object) The average of all HRTs |
RMSSD |
(Numeric) Square root of the mean of the squared successive differences between adjacent intervals of the whole measurement |
(HRTList) A new HRTList object
name
(Character) Name of the vector if given
IL
(Numeric) Arithmetic mean of the overall interval length of the vector
pos
(Numeric vector) Positions of premature ventricular complexes in given input
HRTs
(List) All HRT objects
avHRT
(avHRT object) The average of all HRTs
RMSSD
(Numeric) Square root of the mean of the squared successive differences between adjacent intervals of the whole measurement
After using vectorToHRT
all slots in the resulting HRTList
object are set. Please do not set them manually since many functions of the
HRTList class rely on valid values assigned to the needed slots.
Plots RR-intervals saved in the HRT object and marks turbulence onset and turbulence slope.
## S4 method for signature 'HRT' plot( x, cropped = TRUE, TT = FALSE, pch = 20, xlab = "# of RR interval", ylab = "length of RR interval (ms)", plotLegend = TRUE, paramsLegend = TRUE, pvalsLegend = FALSE, colTO = "#ec2023", colTS = "#006AFF", colTT = "#6800DE", add = FALSE, ... )
## S4 method for signature 'HRT' plot( x, cropped = TRUE, TT = FALSE, pch = 20, xlab = "# of RR interval", ylab = "length of RR interval (ms)", plotLegend = TRUE, paramsLegend = TRUE, pvalsLegend = FALSE, colTO = "#ec2023", colTS = "#006AFF", colTT = "#6800DE", add = FALSE, ... )
x |
(HRT) A HRT object |
cropped |
(Boolean) Should the plot be cut to focus on the HRT parameters? To show all points use FALSE. |
TT |
(Boolean) Should Turbulence timing be marked? |
pch |
(Numeric) Plotting character, for other options see graphics::var |
xlab |
(Character) Label for the x axis |
ylab |
(Character) Label for the y axis |
plotLegend |
(Boolean) Should a legend be plotted? |
paramsLegend |
(Boolean) Should the parameter values of the HRT be plotted? |
pvalsLegend |
(Boolean) Should the p-values of the reliability check be plotted? |
colTO |
(Character) Colour used to highlight TO |
colTS |
(Character) Colour used to highlight TS |
colTT |
(Character) Colour used to highlight TT |
add |
(Boolean) Should the given HRT be added to a plot? |
... |
Other arguments in tag = value form. See graphics::par for more information. |
No return value
Please note that some graphics parameters (par) cannot be modified, since they are needed to be set inside the function.
# You need an HRT object hrt <- vectorToHRT(testdataLong, testdataLong_Ann)@HRTs[[1]] # Plot your HRT and zoom out plot(hrt, cropped = FALSE) # Include TT and customise it plot(hrt, TT = TRUE, colTT = "green", pch = 7) # Use standard graphics parameters ## Note: Some parameters are used inside the function and cannot be set plot(hrt, TT = TRUE, main = "Example plot", bty = "n", cex.lab = 1.2)
# You need an HRT object hrt <- vectorToHRT(testdataLong, testdataLong_Ann)@HRTs[[1]] # Plot your HRT and zoom out plot(hrt, cropped = FALSE) # Include TT and customise it plot(hrt, TT = TRUE, colTT = "green", pch = 7) # Use standard graphics parameters ## Note: Some parameters are used inside the function and cannot be set plot(hrt, TT = TRUE, main = "Example plot", bty = "n", cex.lab = 1.2)
Plots RR-intervals saved in the HRT objects, especially the avHRT object, and marks the HRT parameters.
## S4 method for signature 'HRTList' plot( x, cropped = TRUE, TT = FALSE, pch = 20, xlab = "# of RR interval", ylab = "length of RR interval (ms)", paramsLegend = TRUE, colTO = "#ec2023", colTS = "#006AFF", colTT = "#6800DE", ... )
## S4 method for signature 'HRTList' plot( x, cropped = TRUE, TT = FALSE, pch = 20, xlab = "# of RR interval", ylab = "length of RR interval (ms)", paramsLegend = TRUE, colTO = "#ec2023", colTS = "#006AFF", colTT = "#6800DE", ... )
x |
HRTList |
cropped |
(Boolean) Should the plot be cut to focus on the HRT parameters? To show all points use FALSE. |
TT |
(Boolean) Should Turbulence timing be marked? |
pch |
(Numeric) Plotting character, for other options see graphics::var |
xlab |
(Character) Label for the x axis |
ylab |
(Character) Label for the y axis |
paramsLegend |
(Boolean) Should the parameter values of the HRT be plotted? |
colTO |
(Character) Colour used to highlight TO |
colTS |
(Character) Colour used to highlight TS |
colTT |
(Character) Colour used to highlight TT |
... |
Other arguments in tag = value form |
No return value
Please note that some graphics parameters (par) cannot be modified, since they are needed to be set inside the function.
# You need an HRTList hrtl <- vectorToHRT(testdataLong, testdataLong_Ann) # Plot your HRTList and zoom out plot(hrtl, cropped = FALSE) # Include TT and customise it plot(hrtl, TT = TRUE, colTT = "green", pch = 7) # Use standard graphics parameters ## Note: Some parameters are used inside the function and cannot be set plot(hrtl, TT = TRUE, main = "Example plot", bty = "n", cex.lab = 1.2)
# You need an HRTList hrtl <- vectorToHRT(testdataLong, testdataLong_Ann) # Plot your HRTList and zoom out plot(hrtl, cropped = FALSE) # Include TT and customise it plot(hrtl, TT = TRUE, colTT = "green", pch = 7) # Use standard graphics parameters ## Note: Some parameters are used inside the function and cannot be set plot(hrtl, TT = TRUE, main = "Example plot", bty = "n", cex.lab = 1.2)
Applies a given function on a vector by rolling over it with a sliding window mechanism.
roll(intervals, width, fun, ...)
roll(intervals, width, fun, ...)
intervals |
vector |
width |
window size |
fun |
function to be applied |
... |
additional arguments for FUN |
This method was inspired by the function "wapply" by A. N. Spiess, University Hospital Hamburg-Eppendorf (https://rmazing.wordpress.com/2013/04/23/wapply-a-faster-but-less-functional-rollapply-for-vector-setups/), but adjusted for this package to speed it up.
(list) List with return values of fun for each window
Artificial dummy interval data: This dataset represents a long-term measurement and includes 15 VPCSs that fit the HRT filter rules.
testdataLong
testdataLong
A numeric vector.
Artificial dummy interval data: This dataset contains the annotations matching testdataLong.
testdataLong_Ann
testdataLong_Ann
A vector of characters.
Scans for heart rate turbulence in a vector of RR-intervals and returns an HRTList object including all found HRT objects. The HRT criteria used were published by Schmidt et al. (more information can be found in the vignette.)
vectorToHRT( input, annotations = NULL, PVCAnn = "V", normIL = c_normIL, normHallstrom = TRUE, numPreRRs = c_numPreRRs, numPostRRs = c_numPostRRs, inputName = as.character(NA), minHRT = 5, cleaning = TRUE )
vectorToHRT( input, annotations = NULL, PVCAnn = "V", normIL = c_normIL, normHallstrom = TRUE, numPreRRs = c_numPreRRs, numPostRRs = c_numPostRRs, inputName = as.character(NA), minHRT = 5, cleaning = TRUE )
input |
(Numeric vector) RR intervals in ms |
annotations |
(Character vector) Annotations matching input |
PVCAnn |
(Character) Character that marks a VPC in the annotations |
normIL |
(Numeric) The interval length to which TS should be normalised |
normHallstrom |
(Boolean) Should the normalisation of Hallstrom be used? |
numPreRRs |
(Numeric) Number of RRs before the coupling interval that are used for filtering |
numPostRRs |
(Numeric) Number of RRs after the compensatory interval that are used for filtering |
inputName |
(String) Name of the data |
minHRT |
(Numeric) Minimal number of HRTs that are needed to create an HRTList object |
cleaning |
(Boolean) Should the input be roughly cleaned from artefacts before calculating IL and RMSSD? |
(HRTList) An HRTList object
# You can use annotations to give the VPC indices # Without annotation data RHRT will find VPCs based on common filtering criteria vectorToHRT(testdataLong, annotations = testdataLong_Ann, PVCAnn = "V") # Find HRTs with a broader range of sinus beats before and after the VPCs vectorToHRT(testdataLong, inputName = "Dummy Measurement", numPreRRs = 10, numPostRRs = 20) # Adjust the normalisation parameters vectorToHRT(testdataLong, testdataLong_Ann, normHallstrom = FALSE, normIL = 900)
# You can use annotations to give the VPC indices # Without annotation data RHRT will find VPCs based on common filtering criteria vectorToHRT(testdataLong, annotations = testdataLong_Ann, PVCAnn = "V") # Find HRTs with a broader range of sinus beats before and after the VPCs vectorToHRT(testdataLong, inputName = "Dummy Measurement", numPreRRs = 10, numPostRRs = 20) # Adjust the normalisation parameters vectorToHRT(testdataLong, testdataLong_Ann, normHallstrom = FALSE, normIL = 900)