Next Article in Journal
Toll-like Receptor 9 Gene in the Development of Type 2 Diabetes Mellitus in the Saudi Arabian Population
Next Article in Special Issue
The Intrinsic Cardiac Nervous System: From Pathophysiology to Therapeutic Implications
Previous Article in Journal
Hydroxytyrosol Counteracts Triple Negative Breast Cancer Cell Dissemination via Its Copper Complexing Properties
Previous Article in Special Issue
Central Autonomic Network Regions and Hypertension: Unveiling Sympathetic Activation and Genetic Therapeutic Perspectives
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

CardioRVAR: A New R Package and Shiny Application for the Evaluation of Closed-Loop Cardiovascular Interactions

by
Alvaro Chao-Écija
1,
Manuel Víctor López-González
1,2 and
Marc Stefan Dawid-Milner
1,2,*
1
Autonomic Nervous System Unit, CIMES, School of Medicine, University of Málaga, 29071 Malaga, Spain
2
Biomedical Research Institute of Málaga (IBIMA), 29590 Malaga, Spain
*
Author to whom correspondence should be addressed.
Biology 2023, 12(11), 1438; https://doi.org/10.3390/biology12111438
Submission received: 30 June 2023 / Revised: 25 October 2023 / Accepted: 27 October 2023 / Published: 16 November 2023
(This article belongs to the Special Issue Cardiovascular Autonomic Function: From Bench to Bedside)

Abstract

:

Simple Summary

The main objective of this work was to integrate a review of methodologies to estimate closed-loop baroreflex sensitivity, an index used for autonomic nervous system evaluations, into a new software package, CardioRVAR, developed for the R programming environment. We present the results obtained after applying the tool in different scenarios and discuss its potential applications in a clinical setting. The tool is open-source and stored in a public GitHub repository, which allows feedback and provides room for the improvement and continuation of the work.

Abstract

CardioRVAR is a new R package designed for the complete evaluation of closed-loop cardiovascular interactions and baroreflex sensitivity estimated from continuous non-invasive heart rate and blood pressure recordings. In this work, we highlight the importance of this software tool in the context of human cardiovascular and autonomic neurophysiology. A summary of the main algorithms that CardioRVAR uses are reviewed, and the workflow of this package is also discussed. We present the results obtained from this tool after its application in three clinical settings. These results support the potential clinical and scientific applications of this tool. The open-source tool can be downloaded from a public GitHub repository, as well as its specific Shiny application, CardioRVARapp. The open-source nature of the tool may benefit the future continuation of this work.

1. Introduction

Non-invasive methods to study autonomic functions are common and highly popular in the field of autonomic neurophysiology. We would like to highlight in this context the contributions of Rodríguez-Liñares et al. [1] and Martínez et al. [2] to the R programming environment in the form of the RHRV, a software package designed for the assessment of the state of vagal and sympathetic modulation in individuals through the evaluation of heart rate variability (HRV), estimated from interbeat intervals (IBI) and heart rate (HR) recordings [1,2,3]. In this work, the focus of study comprises both the evaluation of said HRV together with the behavior of the mechanisms that control both HRV and blood pressure variability (BPV).
There are several procedures to estimate HRV and BPV. The procedure of interest in this work is the frequency-domain assessment method, which consists of the identification and isolation of the activity present in two frequency bands associated with adrenergic and vagal modulation: respectively, the low-frequency (LF) band, consisting of frequencies from 0.04 to 0.15 Hz, and the high-frequency (HF) band, which encompasses frequencies from 0.15 to 0.4 Hz [3,4]. These components are extracted from HR and blood pressure (BP) recordings, such as systolic or diastolic blood pressure (SBP, DBP). One should note that, in BPV, this HF band would be representative of the respiratory activity, whose frequency components are usually located at this band [3,4].
In the frequency domain, the magnitude that relates both BPV and HRV is the spontaneous baroreflex sensitivity (BRS) [4]. The BRS can be estimated as the transfer function [4,5,6] between both measurements, which is usually computed as the ratio between the cross-spectrum of the IBI series and the BP recording, and the BP auto-spectrum [5,6], and it is summarized in Equation (1) as described in works such as Barbieri et al. [5] (p. 36) or Faes et al. [6] (p. 278):
α o f = S B P , I B I f S B P , B P f
However, this method assumes an open-loop model to describe the dynamics of the cardiovascular system [5]. A closed-loop model can be used to take into account both feedforward and feedback interactions, in which HR and BP both influence themselves by different mechanisms: either mechanical ones that induce changes in BPV through changes in HRV, or baroreflex ones that induce changes in the opposite direction [5,7]. Moreover, these variabilities may be influenced by other factors external to this closed-loop, which should also be considered [5,7,8].
In this context, several toolboxes that consider this type of model have been designed for MATLAB, most of them based on contributions from Faes et al. [9,10,11], for the analysis of EEG signals and closed-loop cardiovascular data. From these MATLAB tools, we highlight the eMVAR toolbox [9] (http://www.lucafaes.net/emvar.html (accessed on 30 August 2023)) and the blockMVAR toolbox (http://www.lucafaes.net/blockmvar.html (accessed on 30 August 2023)), designed for the evaluation of causal relationships between variables through autoregressive modeling [8,9,12]. It is also worth mentioning the works of Barnett and Seth in the form of the GCCA [13,14] and MVGC [15] MATLAB toolboxes, which, although designed for and centered on neural connectivity analysis, share both procedures and core algorithms with the ones employed to analyze closed-loop cardiovascular data.
In the R statistical environment, the authors have recently proposed a software tool for the determination of spontaneous BRS changes using wavelet analyses [16]. In addition, we highlight R-based package grangers (https://github.com/MatFar88/grangers (accessed on 30 August 2023)), by Farnè and Montanari and based on their work [17], which allows causal analysis between pairs of signals. However, the R environment lacks sufficiently specific and detailed contributions such as the ones designed for MATLAB for the measurement of baroreflex sensitivity using causal closed-loop models of interactions.
We present in this work the R package CardioRVAR, a tool developed in the R environment to better describe these interactions in individual subjects by working at the same time with both the present feedback and feedforward mechanisms that regulate the studied variables, using the R statistical environment for data analysis. In the following sections of this work, a review of the methodology integrated into the package will be presented, as well as the general workflow of the package.

2. Materials and Methods

2.1. Vector Autoregressive Models

The core of this work is centered on the computation of vector autoregressive (VAR) models [5,6,8,9,12,13,14,15,17,18,19]. These models are able to describe causal interactions between lagged values of the modeled variables against themselves as well as against the other involved variables, until a specific lag conventionally denoted as p is reached, a limit that corresponds to the order of the VAR model [5,6,8,9,12,13,14,15,17,18,19]. Equation (2), as in Barnett and Seth [15] (pp. 52–53) or Faes et al. [6] (p. 278), describes the general structure of a bivariate VAR(p) model [5,17], modified as in Faes et al. [9] (p. 4) to include a(0) coefficients in the structure:
y n = k = 0 p a 11 k y n k + k = 0 p a 12 k x n k + w y n x n = k = 0 p a 21 k y n k + k = 0 p a 22 k x n k + w x n
If this model were to be applied to a system describing the interactions between variables x and y, the first branch of Equation (2) would represent the main process of this system (e.g., how HRV influences BPV) whereas the second would describe a feedback controller for the main process (e.g., the baroreflex interaction between BPV and HRV) [5,8]. One should note that the traditional VAR model only considers lagged interactions; therefore, all direct and instantaneous interactions would be due to the model residuals, and a11(0) = a12(0) = a21(0) = a22(0) = 0 [8,19]. By applying the Fourier transform on the autoregressive coefficients as described in Equation (3) [5] (p. 35) [9] (p. 4), one can obtain the frequency-domain representation of these coefficients, and, thus, of the whole model, as presented in matrix notation in Equation (4) [5] (p. 35):
A f = k = 0 p a k e i 2 π f k  
Y f X f = A 11 ( f ) A 12 ( f ) A 21 ( f ) A 22 ( f ) Y f X f + W Y f W X f  
From Equation (4), one can derive the functions that constitute the closed-loop transfer functions for each branch of the system. Equations (5) and (6) represent, respectively, the transfer functions of the main process and the feedback controller described in Equation (2), as discussed in Barbieri et al. [5] (p. 35):
β c f = A 12 f 1 A 11 f  
α c f = A 21 f 1 A 22 f  
However, this model, in the context of cardiovascular variables, is actually biased [7,8,9]. In order to correct it, direct transfer paths not previously included should be allowed from one of the variables to the other [7,8,9,19]. By rearranging Equation (4), one can arrive at the following matrix equation, given by Equation (7) as in Barbieri et al. [5] (p. 36) or Barnett and Seth [15] (p. 52):
S = H Σ H *  
Here, S is a matrix representing the frequency-domain cross-spectral matrix of the previous variables X and Y, whereas Σ represents the noise-covariance matrix of the model, and H is a matrix containing the transfer functions that link the activity of the estimated noise sources of the model to the modeled variables [5,8,13,15,19]. In addition, operator * applied to matrix H in Equation (7) represents its conjugate transpose [8,13,15,19]. Matrix Σ will therefore contain every direct instantaneous interaction in the model, as the main model is designed so that its coefficients represent the captured lagged interactions [8]. These instantaneous interactions can be isolated and incorporated into the main structure of the model by estimating a matrix of interactions capable of diagonalizing the original matrix Σ [8,9,19]. This process is described in Equation (8) [8] (p. 104):
Σ = D Σ d i a g D T
Then, the coefficients of matrix D will be incorporated into matrix H and will be propagated back to the transfer functions previously described in Equations (5) and (6) [8]. This makes either a12(0) ≠ 0 or a21(0) ≠ 0, depending on which direct transfer path is selected, as these paths are unidirectional, while generating a new noise-covariance matrix [8,9,19]. Not only are the corresponding transfer functions estimated, but also one can evaluate the specific contribution that each noise makes to each variable, which can be indicative of the causal strength in the interactions among the modeled variables [8]. These computations and transformations are applied to the frequency-domain representation of the model, but they could also be performed on the time-domain model [9,19]. The time-domain representation of this type of MVAR model is defined by Faes et al. [9,19] as its extended version and also represents the core of the eMVAR MATLAB toolbox.

2.2. Causal Coherence and Noise Contribution

We integrated in our package the computation of the causal coherence measure, based on the works of Porta et al. [18] and Faes et al. [6,9,19]. As explained in the literature [6,9,18,19], the causal coherence of a bivariate series refers to the value of the spectral coherence after suppressing one of the possible causal interactions, i.e., turning to zero a specific portion of the matrix of interactions of the modeled system, representative of a certain interaction. Therefore, the spectral coherence and the causal coherence can be defined using Equations (9) and (10), respectively, as reported in Porta’s work [18] (p. 243):
c o h 2 S B P , I B I f = S S B P , I B I f 2 S S B P , S B P f S I B I , I B I f
c o h 2 S B P I B I f = c o h 2 S B P , I B I f | H S B P , I B I ( f ) = 0
Causal coherence therefore would measure the coupling strength of a single interaction. The measurement of causal coherence can also be used as an indicator of baroreflex mechanisms [6,18]. A related measure to the causal coherence is the noise source contribution measure, which is also related to causal interactions [8]. As defined in the literature, the noise source contribution is calculated as the percentage of a certain spectrum that is explained by a particular noise source [8]. In a bivariate process, such as an IBI-SBP model, the IBI spectrum is influenced by both the IBI white noise source and, to a certain degree, the SBP noise source [8].

2.3. Trend Removal with the Discrete Wavelet Transform

In addition, a brief summary of the discrete wavelet transform [20] (DWT) is given here, as it has been considered for the preprocessing algorithms of this software. The DWT is able to decompose a signal into detail [20,21] and approximation or smooth coefficients [20,21], each contained in a specific decomposition level representing a frequency band, whose limits are defined by powers of two [20,22]. The frequency ranges contained in each band are determined by the number of decomposition levels applied, and the so-called Nyquist frequency (i.e., half of the sample frequency of a given signal) [20,22]. In this work, this decomposition is performed with the maximal overlap discrete wavelet transform (MODWT) [21]. An example of the result of this type of decomposition algorithm on a given signal and its potential to isolate and detrend said signal is depicted in Figure 1 and Figure 2, in which decompositions were performed using the Haar [22,23] wavelet. In Figure 2, an additional border handling strategy [24] is added to the decomposition, therefore producing a different representation of the coefficients.
As one can observe in Figure 1, due to the applied number of decomposition levels, the approximation coefficients form a representation of a very-low-frequency trend of the signal, while the detail coefficients contain information for each analyzed frequency band, represented by a specific decomposition level. This allows the design of an algorithm capable of isolating such trends, which consists of editing the coefficients calculated from the decomposition process by comparing each coefficient to a certain threshold [25,26]. After the coefficients have been edited, an inverse transform is performed to estimate and then subtract a trend from the original signal, resulting in a detrended version of said signal [25,26]. While other detrending methods, such as the smoothness priors [25,26,27], could also be performed, the wavelet detrending method achieves the desired results in a more computationally efficient manner [25,26]. The importance of this detrending process will be discussed in the following sections.

2.4. CardioRVAR Workflow

The discussed tool is currently stored in two GitHub repositories. The first one, CardioRVAR, allows the user to work with an R package and to use the provided functions directly in the R console. The second one, CardioRVARapp, houses a Shiny application (https://shiny.posit.co/ (accessed on 15 October 2023)) [28] that can automate the available routines of CardioRVAR through a graphical user interface. CardioRVAR operates on the algorithms previously described to achieve a complete profile of the cardiovascular interactions present among HR and BP variables. The software algorithm can be summarized into the following steps:
  • Select a data file with CardioRVARapp and upload it into the software structure;
  • Resample the uploaded time series after selecting a certain frequency, if needed;
  • Manually select from the estimated HR and BP recordings a specific time window of interest;
  • Preprocess the windowed data, first by subtracting the mean of each series and then by detrending them with an adaptative MODWT-based algorithm, and validate them accordingly [13,14] for further analyses;
  • Estimate a time-domain VAR(p) model from the validated chosen segments and then diagnose and validate the model with the criteria described in the literature [13,14,15,29];
  • Transform the model into the frequency domain;
  • Extract instantaneous unidirectional interactions from this frequency-domain representation, given a specific zero-lag-interaction path already chosen by the user, and update the model with such interactions;
  • Estimate the most important features of the model and then display and report them;
  • Generate and report single-subject indices from the model, allowing the user to choose a method to estimate said indices.
This workflow can be achieved using the functions provided in the CardioRVAR package, or automatically by using the graphical user interface CardioRVARapp. The workflow will be discussed in more detail in the following subsections, and transcripts of the required commands from the current version of CardioRVAR will be provided.

2.5. Data Upload and Preprocessing

After uploading a data file, several functions can be used to preprocess said data. The first preprocessing steps would be to interpolate and detrend the data, as well as to assess their stationarity, as indicated in the literature [1,13,14,15,29,30]. This can be achieved by using the following commands.
> library(CardioRVAR)
> # Data is a list with elements Time, RR, and SBP:
> Data <- ResampleData(Data, 4) # Interpolates data
> IBI <- DetrendWithCutoff(Data$RR) # Detrends IBI signal
> SBP <- DetrendWithCutoff(Data$SBP) # Detrends SBP signal
> New_Data <- cbind(SBP = SBP, RR = IBI)
> CheckStationarity(New_Data) # Checks stationarity of the data
[1] TRUE
> # Or alternatively:
> Check_stationarity <- CheckStationarity(New_Data, verbose = TRUE)
Time series are stationary
CardioRVAR’s graphical interface allows one to upload data from csv and txt files, which contain information regarding beat-to-beat BP and IBIs. During the program testing, these csv files were obtained from the ACQKnowledge v4.2.0 software. The application also offers the possibility to interpolate each recording, if not done yet, to a sample frequency of 4 Hz by default, as suggested in the literature [1,30]. After uploading the data, a visual representation of the HR tachogram associated with the SBP data will be displayed on-screen. The user will now have the possibility to select a time window to isolate a specific interval from the recording for its analysis. Mean HR and SBP values of the isolated segments will be reported once the window is selected. Figure 3 depicts this interface and this process.
Once a time window has been chosen, the windowed signals are then preprocessed by the R package, which results in detrended segments of the original signals through the MODWT algorithm, adjusted through a border handling strategy (Figure 2) by default. The detrending process is necessary for two main reasons: first, the detrending method has been designed to mitigate the effects of the very-low-frequency (VLF) band [3,27], as shown in Figure 4; second, the detrending allows one to make the data stationary, which is a necessary step in order to further analyze the data [13,14]. As with the smoothness priors detrending method, for which a frequency cutoff can be selected to better perform the detrending [25,27], the nature of the MODWT allows one to define a frequency cutoff, or a reference frequency from which the cutoff can be computed, that will determine which frequency bands will be contained in the estimated trend [25].
Based on the strategy suggested by Li et al. [25], the detrending method included in CardioRVAR adapts the number of decomposition levels to the sample frequency of the series, in combination with a desired cutoff or reference frequency provided by the user. For a specific decomposition level d, a frequency cutoff fC would be defined by Equation (11), as the allowed frequency bands’ limits are powers of two and depend on the Nyquist frequency fN [20,22,25]:
f C d = f N 2 d
If a reference frequency is set by the user instead of a proper cutoff, the cutoff will be computed as the lower limit of the frequency band to which the reference frequency belongs. In other words, if a frequency fref is selected, CardioRVAR will find a decomposition level associated with an interval of possible reference frequencies f C d , f C d 1 that contains fref and will use said interval to select frequency f C d as the cutoff. By reordering Equation (11), and adapting it to include reference frequencies, we can obtain Equation (12), which integrates the described steps and generates the optimal decomposition level according to a reference frequency lower than the Nyquist frequency, with · representing the ceiling operator:
d = log 2 f N log 2 f r e f
For a reference frequency of 0.04 Hz, as in Li et al. [25], and a sample frequency of 4 Hz, the detrending algorithm will generate a six-level decomposition, in which the last decomposition level will contain a frequency band between 0.03125 Hz and 0.0625 Hz. From this band, its lower limit, which is also the upper limit of the frequency band represented by the approximation coefficients, will be used as a cutoff. CardioRVAR assumes by default a sample frequency of 4 Hz and uses a reference frequency from the interval [0.03125 Hz, 0.0625 Hz) (e.g., 0.04 Hz, the lower limit of the LF band), and therefore the frequency 0.03125 Hz, as suggested by Li et al. [25], as a cutoff to estimate the trend, reducing the VLF component of the signal (Figure 4B).
This cutoff can be modified by the user so as to ensure the stationarity of the detrended signals: the lower the frequency cutoff, the more the VLF component is retained, while this component will be more mitigated if the cutoff is increased (Figure 4C). By selecting, for example, a reference frequency from the interval [0.0625 Hz, 0.125 Hz) (e.g., 0.07 Hz), a five-level decomposition will be performed, and the frequency 0.0625 Hz will be used as a cutoff. Using a high cutoff or reference frequency, however, may also have the undesirable effect of affecting the spectral components of interest, especially the LF component, as shown in Figure 4C.
Moreover, the use of a specific wavelet to perform the detrending is important as, apart from mitigating the VLF components, it is desirable to preserve the HF and LF components as much as possible. An example of the importance of this choice is shown in Figure 5, where the relative errors between the non-parametric spectra of a raw IBI signal and its detrended version using the MODWT-based algorithm included in CardioRVAR are depicted. Two different wavelets were used to perform the detrending, the Haar and the Daubechies 8 [23] wavelets, which are commonly renamed in R packages such as RHRV as haar and d16, respectively [23]. While both wavelets generate high relative errors below 0.04 Hz, indicating that the VLF component has been mitigated, the Daubechies 8 wavelet tends to maintain lower relative errors for the HF and LF components than the Haar wavelet. This indicates that the former is better for preserving these HF and LF components and therefore is more suitable for the detrending process. CardioRVAR allows the use of several wavelets to modify the detrending and operates with the Daubechies 8 wavelet by default.
After this detrending is performed on the windowed data, CardioRVAR then tests each segment to check if they are stationary. As suggested by Seth’s work [13,14] on the use of MVAR models to describe and analyze neurological connectivity, the augmented Dickey–Fuller (ADF) and the KPSS tests are employed for this task. Once the detrended segments are statistically confirmed to be stationary, CardioRVAR starts the data modeling.

2.6. Analysis of Cardiovascular Closed-Loop Interactions

Once the data have been preprocessed, CardioRVAR proceeds to generate a VAR(p) model of the chosen segments, which will be defined by a specific model order or maximum lag limit and will capture the interactions of interest present at said segments. This model order is usually chosen by applying an information criterion, which, in the case of CardioRVAR is, by default, the Akaike Information Criterion (AIC) [31,32], as suggested by authors such as Faes et al. [9] regarding closed-loop cardiovascular analysis. However, the software allows one to select the model order that users consider more appropriate. It should be noted that very low model orders will decrease the resolution of the frequency-domain results, and too high model orders will produce extra peaks in the variability spectra that may deviate from the true frequency-domain representation of the studied signals [32].
Once the model is estimated, certain statistical criteria are used to validate it. These criteria are widely reported in the literature and consist of assessing the stability of the model and the white noise nature of the model residuals [13,14,15,29]. While the validation criteria used by CardioRVAR were proposed in the context of neural connectivity analysis, the systems that are analyzed in said context share similar properties with the ones analyzed in a cardiovascular one, such as the possible presence of cross-correlated noise sources in the systems [8,13]. This justifies the use of said criteria for cardiovascular analyses. CardioRVAR reports both these features, as well as the best model order according to the chosen information criterion, the AIC by default, for a specific multivariate signal. When a valid model has been estimated, one can use it as a source to calculate frequency-related data. CardioRVARapp performs this routine automatically using its graphical interface; if the user wants to do this by themselves using the functions provided by CardioRVAR, the following are the commands that should be used.
> # Data represents a matrix with two interpolated time series, IBI and SBP.
> Data[,“IBI”] = DetrendWithCutoff(Data[,“IBI”])
> Data[,“SBP”] = DetrendWithCutoff(Data[,“SBP”])
> # Both signals have been detrended with these commands.
> CheckStationarity(Data)
[1] TRUE
> # A VAR model is estimated from the stationary time series and then validated:
> model <- EstimateVAR(Data)
> Check_residuals <- DiagnoseResiduals(model, verbose = TRUE)
Model residuals are white noise processes
> Check_stability <- DiagnoseStability(model, verbose = TRUE)
The model is stable
With these commands, once the data have been checked for stationarity, a model can be estimated from the data and can also be checked to ensure its validity. The estimated model can then be used to further assess its properties in the frequency domain.

2.7. Analysis in the Frequency Domain

The main functionality of CardioRVAR is to transform the time-domain VAR(p) models into their frequency-domain representations. To do so, one should use the following command, which will be applied to the previous model object:
> freq_model <- ParamFreqModel(model).
When calculating this new representation, the software estimates both branches of the cardiovascular closed-loop model and allows users to choose which branch of the model should be evaluated by selecting a specific input and output. If SBP (HR) is the input (output), baroreflex interactions will be evaluated. On the contrary, mechanical effects will be evaluated if HR (SBP) is chosen as the input (output).
CardioRVAR allows users to choose a direct transfer path from one of the variables into the other. Although users are free to choose which direct transfer path they wish to include in the model, from SBP to HR or vice versa, we strongly suggest the former option, as the literature considers this a means of including fast baroreflex interactions in the model [6,8]. For this reason, CardioRVAR also reports these instantaneous interactions after isolating them from the frequency-domain representation of the model.

2.8. Assessment of the Transfer Functions

CardioRVARapp is able to display three types of transfer functions (Figure 6). The first one is a biased representation of the closed-loop transfer function, as it is calculated without taking into account the chosen direct transfer paths and is only shown for comparison purposes. The second one is the corrected closed-loop transfer function, adjusted to allow these direct transfer paths. The third one is the classical open-loop transfer function, obtained either from Equation (1) or as the type I index indicated by Barbieri et al. [5] (p. 36). All the representations are accompanied by their respective indices to allow statistical comparisons. The interpretation of these transfer functions depends on the evaluated arm of the loop: for example, Figure 6 depicts the calculated transfer functions with SBP (HR) as the main input (output) of the arm, with a direct transfer path from SBP to HR, which is also reported by the software (not shown in the figure). This transfer function represents the baroreflex sensitivity of the analyzed data.
Several methods have been introduced in CardioRVAR to estimate expected values from the computed transfer functions. The first method is to perform this estimation by simply reporting the arithmetic mean of the transfer function at each frequency band of interest. This method, however, is not recommended as it does not evaluate the reliability of the estimates and could induce misrepresented expected values [33,34]. Thus, other methods were introduced in the package to tackle this problem. The second one is the classical thresholding method, which makes use of the squared spectral coherence to estimate the reliability of the data by only considering estimates whose associated coherence values surpass a certain threshold, which is usually 0.5 n.u. [8,33]. This method, however, can be too strict to the point of sometimes not obtaining valid estimates from a particular subject due to low coherence values [34,35]. The method proposed by McLoone and Ringwood [35] was also introduced in our software, which consists of applying a frequency-domain Gaussian window to the transfer function at a specific band before computing the expected values. As both authors point out, with this method, the center of each frequency band is mainly considered for the evaluation of the baroreflex activity [35]. Finally, another estimation method, which consists of reporting the value of the transfer function at the maximum coherence value of the bands of interest [36], is also included in our software.

2.9. Assessment of the Noise Source Contribution and Causal Coherence

As the computed models consider noise sources, one can evaluate their contribution to the variability of the analyzed segment. This is reported by CardioRVAR in two different ways: first, the software reports the percentage of this contribution as defined by Hytti et al. [8], from each noise source to each type of variability (Figure 7); second, it can be achieved as a frequency-domain causal coherence function. This can also be interpreted as a causality measure: the more that one type of variability can be explained by external noise sources concerning a certain variable, the stronger these causal interactions [8]. Figure 7 depicts an example of a noise source evaluation obtained from a patient before and during a head-up tilt (HUT) test, which was displayed by CardioRVARapp.

2.10. Evaluation of the Tool: Data Sources

In this work, we present three analyses conducted with the tool in order to test its effectiveness. The first analysis consists of the descriptive study of different autonomic and baroreflex features from two subjects: a healthy subject and a patient with Postural Orthostatic Tachycardia Syndrome (POTS) induced by COVID-19, the latter of which is a phenomenon that has been recently reported in the literature [37]. The second analysis consists of a comparison of estimates produced from the tool from five individual normotensive subjects and seven hypertensive subjects in the context of HUT sessions. In the final analysis, estimates computed with the tool from subjects from the EUROBAVAR data set [34] are compared in the supine and standing positions, a validation strategy already used in other works [16,35,38,39]. For these two last analyses, the normality of distributions in the former analysis and of the difference in distributions in the latter is tested with the Shapiro–Wilk test. Then, depending on whether normality can be rejected or not, a Wilcoxon test or a t-test for unpaired samples, in the case of the former analysis, and for paired samples, in the case of the EUROBAVAR data, is performed to compare the estimates, assuming a confidence level of 0.95. More information regarding the composition of this data set, which includes two baroreflex-impaired subjects, is available in the work of Laude et al. [34].

3. Results and Discussion

3.1. Descriptive Study of Two Subjects

We offer a practical example in which our software was used to evaluate cardiovascular interactions from certain subjects, who will be referred to as subjects A and B. Both subjects participated in a HUT test, during which HR and beat-to-beat non-invasive SBP recordings were obtained. In each example, three intervals were considered for the analysis, which will be referred as pre-tilt, tilt, and post-tilt. A closed-loop model of interactions was estimated for each interval using CardioRVAR, and the BRS transfer functions, as well as the feedforward transfer functions, were isolated from each model. To ensure the reliability of the measurements, the spectral squared coherence, also computed by CardioRVAR, was considered alongside each transfer function, and only those frequencies whose spectral coherence was higher than 0.5 n.u. were used in the computations. For comparison purposes with the coherence-thresholding method, estimates were also recovered using the other estimation strategies available in CardioRVAR.
The obtained closed-loop BRS indices from these subjects are reported in Table 1. Subject A exhibits a weak response during tilt (Figure 8A), with a rather bradycardic behavior. As can be seen, weak changes in HR rate and SBP are found in this subject during each interval of the HUT test. However, changes in the baroreflex components are highly evident. The HF component of the BRS is highly predominant during the pre-tilt and post-tilt periods, which could be correlated and would explain the bradycardic basal state of this subject. In fact, the coherence levels are below 0.5 n.u. for the LF band during post-tilt, making the BRS estimate unreliable according to the coherence threshold criterion for said band. The Gaussian-averaging estimation and the estimate at maximum coherence methods are able to give individual estimates for these intervals. However, during post-tilt, they differ in their magnitudes for the LF band: after visual inspection, it was noticed that around 0.06 Hz, where the maximum coherence level was located, the gain of the transfer function dropped, giving a low estimate for this coherence level, while, at frequencies around 0.1 Hz, the gains computed were of much higher magnitude. Therefore, we attribute this finding to the fact that the maximum coherence level, at which the gain dropped, was not located near the center of the frequency band, a region that is better explored by the Gaussian-averaging method [35], which in this case had gains of greater magnitude. During tilt, the response at the HF band is reduced, but the activity of the LF component is still not predominant.
Subject B, who participated in a similar protocol, exhibited, however, an intense response during tilt (Figure 8B). This subject had recovered from COVID-19 infection and was suffering from long-COVID-induced POTS. The data were analyzed by the software and its corresponding results are also reported as with subject A in Table 1. As can be seen, the strong HR response during tilt is accompanied by a strong decrease in the HF baroreflex component according to the non-thresholding estimation methods, and a decrease in the coherence levels below the threshold, thus not allowing a correct estimation for this band according to the coherence criterion method. The LF component also decreases, but tends to be predominant during tilt according to the non-thresholding estimation methods. Both components increase again after HUT.

3.2. Comparison between Normotensive and Hypertensive Subjects

Table 2 summarizes the obtained results from seven hypertensive and five normotensive subjects from the analysis of recordings from HUT tests. Two methods for the estimation of BRS were used in the analyses: a weighted-averaged BRS without coherence thresholding, as in McLoone and Ringwood’s work [35], and BRS indices obtained at the maximum coherence level for each frequency band. Significant differences are found for both bands in the supine position, and for the LF band during HUT; however, disagreement between the estimation methods is detected at the LF band in the supine position.
No significant differences were found for the HF band during HUT. In certain distributions, normality was rejected through the Shapiro–Wilk test due to the presence of extreme values in said distributions. These extreme values were mainly attributed to the previously discussed subject A, who was included among the normotensive subjects and whose characteristics were previously discussed. One should note that both strategies to compute the BRS tend to share the same statistical conclusions, except for the LF band during supine rest, for which the estimates produced by windowing and averaging through the frequency band were not considered to have a statistically significant difference, whereas the estimates produced by considering the BRS at its maximum coherence level did, although a tendency was evidenced regarding the weighted-averaged estimates. The significant differences found between normotensive and hypertensive subjects correlate with findings reported in the literature, which show that hypertensive patients tend to have lower BRS levels when compared to normotensive ones [40].

3.3. EUROBAVAR Analysis Results

We also tested the tool on the open-access EUROBAVAR data set, as done in previous works in the literature [34,35,38,39], including the evaluation of our previous contribution [16]. Preliminary results from the closed-loop BRS assessment from the EUROBAVAR data have been previously presented at a Spanish Society of Physiological Sciences meeting [41]. A set of individual results obtained through the maximum coherence method from each subject is displayed in Figure 9 and Figure 10, divided according to the reported A and B series of the data set [34,38]. For each of these subjects, after uploading their respective recordings into CardioRVARapp and preprocessing them, a bivariate VAR model was estimated to model each arm of the closed loop and was transformed into the frequency domain, while incorporating an instantaneous transfer path from BPV to HRV. Then, CardioRVARapp-reported estimates from these models were then computed using the maximum coherence strategy (Figure 9 and Figure 10) or McLoone and Ringwood’s weighting strategy.
It should be noted that although McLoone and Ringwood originally applied their weighting method on the EUROBAVAR data set, the strategy was applied to models derived from a direct approach strategy proposed by both authors, analyzing the closed-loop baroreflex system as if it were an open one [35]. CardioRVAR, however, aims to follow a different approach, by considering both arms of the closed-loop system in its computations and combining the computed models with the previously described individual estimation strategies. By applying its entire workflow to these data, and through the comparisons of the obtained results with the available works on this data set, the performance of CardioRVAR in this setting can be validated.
For comparison purposes, estimates computed through the coherence-thresholding strategy for the A series (Figure 9C,D) and the B series (Figure 10C,D) are also shown together with the ones computed through the maximum coherence strategy. It can be noticed that the coherence-thresholding strategy is not able to produce estimates from certain subjects, particularly from the B series: regarding the impaired subjects [34,35,38], both estimates could be recovered from one of these subjects in the supine position, while estimates from the other one could not be recovered from any band. In the standing position, only estimates for the HF band could be computed from these subjects. This not only affected the impaired subjects, but also some of the non-impaired ones (Figure 9B and Figure 10B,D). The maximum coherence strategy, however, is able to produce estimates for both bands of interest for every subject in the data set, which tend to be similar to the ones produced through the coherence-thresholding strategy. The estimates computed by CardioRVAR correlate with findings described in the literature: the baroreflex impairment tends to be better assessed qualitatively in the standing position [35], allowing the identification of the two impaired baroreflex subjects [35]. There is also an extreme baroreflex component in subject 13 from the B series, visible in the supine position (Figure 10A,B), expected according to the literature [38], which shares characteristics with the previously discussed subject A. Subject A008 also tends to give high BRS values for the HF band when compared to the rest of the A series, which is similar to what was observed by McLoone and Ringwood through their methodology [35].
Figure 11A shows changes in baroreflex sensitivity estimates assessed by the CardioRVAR after applying McLoone and Ringwood’s weighting method to the computed VAR models for all patients, excluding subjects 5 and 10 from the B series due to their baroreflex impairment as in [16], showing significant differences between the supine and standing positions for the HF band (p < 0.001) and the LF band (p < 0.001), with supine-to-standing rations of (mean ± S.D.) 3.21 ± 1.44 and 1.98 ± 0.88 for each band, respectively. Figure 11B shows the same estimates after applying the maximum coherence strategy, obtaining supine-to-standing ratios of 2.89 ± 1.17 and 1.91 ± 1.21 for the same bands, respectively. Significant differences between the supine and standing positions for the HF band (p < 0.001) and the LF band (p < 0.01) were also observed again. These results are summarized in Table 3, which also shows estimates obtained from open-loop strategies, classified as types I and II according to Barbieri et al. [5]. While these estimates were computed through the Gaussian-weighting and the maximum coherence procedures, they share several properties already described for open- vs. closed-loop estimates [5]: type I open-loop estimates tend to be higher than type II estimates, and closed-loop estimates tend to be smaller than open-loop ones, as shown in Table 3. The overall significant differences found between the estimates also correlate with other results reported in the literature [16,35,39], validating the ability of CardioRVAR to identify these features.
An analysis of causal coherence (Figure 12, Table 4) in both positions was performed on the same subjects, which revealed, as briefly reported in the Spanish Society of Physiological Sciences meeting [41], that the IBI-to-SBP coherence was significantly higher than the SBP-to-IBI one for the LF band in the supine position (p < 0.001), whereas, in the standing position, both coherence flows were statistically equally predominant. For the HF band, no significant changes in causal coherence were observed. The changes observed in the causal coherence in the LF band are important in the context of BRS, as they follow a similar pattern as reported in the literature, which is indicative of baroreflex mechanisms taking place in the analyzed system [6].

3.4. Comparison with Other Works

A comparison with other works published in the literature is provided. As explained before, the preprocessing steps used in CardioRVAR to validate the produced VAR models are based on the preprocessing workflow proposed by Barlett and Seth in their works [13,14,15]. In CardioRVAR’s workflow, the discrete wavelet transform is used in the preprocessing steps of the signals, but not in the analyses per se. This differs from a recently published package from our team, BaroWavelet [16], in which wavelet transforms are used as the core of the analysis of the BRS. In this sense, BaroWavelet offers particular utility regarding BRS analysis, which is the application of the multiresolution approach of the wavelet transform for a time-frequency assessment of the BRS, aiming for the isolation of both time and frequency components at the same time while mitigating the possible loss of information in these components [16]. Here, CardioRVAR can only provide analysis results in the frequency domain. However, it should be highlighted that the main focus of CardioRVAR lies in the obtention of closed-loop interaction models of the cardiovascular dynamics. Thus, the simultaneous use of both tools could probably allow the obtention of a more complete overview of the cardiovascular profile, through the combination of both methodological strategies offered by each tool.
CardioRVAR also allows users to choose amongst several different strategies to compute estimates from the frequency-domain models. The results depicted in Table 1 as well as Figure 9 and Figure 10 serve as examples of why several estimation methodologies that allow the computation of as many estimates as possible while maintaining the reliability of said estimates at the same time must be included in the software, which is in line with the opinions of several authors [34,35]: estimates from certain subjects may be compromised due to the application of harsh validation methods, such as the application of a coherence threshold (Figure 10B,D), in which case a softer validation strategy could be appropriate to compute said estimates (Figure 10A,C). Thus, CardioRVAR includes several coherence-independent mechanisms described in the literature and reviewed in this work to produce these estimates, apart from the classical coherence-thresholding method.
The package grangers, also developed for R, offers a very useful set of tools to analyze causal connectivity between sets of signals, which represents another way to demonstrate the presence of causal baroreflex interactions among the measured recordings. However, it does not consider a detailed analysis of the transfer functions that define this system of interactions. Its usage in combination with CardioRVAR is nevertheless highly suggested, as grangers can also generate frequency-domain significance testing results for the evaluation of the present causal interactions [17].
Although the package RHRV is not specifically designed to analyze BRS, its contribution to the R environment for the analysis of HRV is outstanding. The package BaroWavelet was in fact designed to work together with the RHRV algorithms to produce some of its BRS estimates [16]. While this is not the case for CardioRVAR, we strongly encourage its use in combination with RHRV in order to generate a complete assessment of the cardiovascular profile.
Finally, it should be noted that CardioRVAR, when compared with other tools for closed-loop BRS assessment, is also accompanied by a graphical user interface to simplify the analysis for users. In this way, users that are not used to the mechanics of the R environment can conduct the same analyses with the help of the interface. This strategy was also followed for the BaroWavelet package [16], for the same reasons.

4. Conclusions

In this work, a new R package and Shiny application capable of evaluating closed-loop cardiovascular interactions have been described. A review of the methodological aspects of the tool is provided, and several demonstrations of analyses performed by the tool are given. These analyses tackled the characterization of postural changes and baroreflex impairment, the identification of decreases in baroreflex sensitivity caused by hypertension, and a descriptive analysis in the context of COVID-19-induced POTS. With these results, the potential clinical and scientific applications of this R-based package, CardioRVAR, have been highlighted. This package therefore serves as a contribution to the R statistical environment, allowing the analysis of closed-loop cardiovascular dynamics through the reviewed algorithms.
The tool can be accessed through two public GitHub repositories, for both the main package, through the URL https://github.com/CIMES-USNA-UMA/CardioRVAR, and its graphical user interface through https://github.com/CIMES-USNA-UMA/CardioRVARapp. Thanks to the nature of this package, new updates can be introduced in the future to further improve its structure and data analysis algorithms, enabling the possible continuation of this work.

Author Contributions

A.C.-É. contributed to the software development and validation and wrote the first manuscript draft and revisions. M.V.L.-G. collaborated in the statistical study. M.S.D.-M. designed the study and contributed to data collection, data analysis, interpretation, and revisions to the manuscript. All authors have read and agreed to the published version of the manuscript.

Funding

The study was supported by a program grant from Junta de Andalucía, Group No. CTS-156, Spain. Part of the final study was supported by the Own Funds Program of the University of Málaga.

Institutional Review Board Statement

The studies involving human participants were approved by the Experimentation Ethics Committee of the University of Málaga (CEUMA 125-2023-H). The data allocated in the EUROBAVAR data set were approved by the Paris-Necker Committee.

Informed Consent Statement

Informed consent was obtained from all subjects involved in the study.

Data Availability Statement

The EUROBAVAR data set is available in open-access format. The raw data supporting the conclusions of this article will be made available by the authors, without undue reservation.

Acknowledgments

The authors of this work would like to acknowledge Francisco Javier Barón López and Francisco Javier Mata Contreras for their advice and comments regarding both the structure of the discussed project and the creation of its graphical user interface, as well as the publication of the work in the GitHub repositories.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Rodríguez-Liñares, L.; Méndez, A.J.; Lado, M.J.; Olivieri, D.N.; Vila, X.A.; Gómez-Conde, I. An Open Source Tool for Heart Rate Variability Spectral Analysis. Comput. Methods Programs Biomed. 2011, 103, 39–50. [Google Scholar] [CrossRef] [PubMed]
  2. Martínez, C.A.G.; Quintana, A.O.; Vila, X.A.; Touriño, M.J.L.; Rodríguez-Liñares, L.; Presedo, J.M.R.; Penín, A.J.M. Heart Rate Variability Analysis with the R Package RHRV; Springer International Publishing: Cham, Switzerland, 2017; ISBN 978-3-319-65354-9. [Google Scholar]
  3. Task Force of the European Society of Cardiology and the North American Society of Pacing and Electrophysiology. Heart Rate Variability: Standards of Measurement, Physiological Interpretation and Clinical Use. Circulation 1996, 93, 1043–1065. [Google Scholar] [CrossRef]
  4. Swenne, C.A. Baroreflex Sensitivity: Mechanisms and Measurement. Neth. Heart J. 2013, 21, 58–60. [Google Scholar] [CrossRef]
  5. Barbieri, R.; Parati, G.; Saul, J.P. Closed- versus Open-Loop Assessment of Heart Rate Baroreflex. IEEE Eng. Med. Biol. Mag. 2001, 20, 33–42. [Google Scholar] [CrossRef]
  6. Faes, L.; Porta, A.; Antolini, R.; Nollo, G. Role of Causality in the Evaluation of Coherence and Transfer Function between Heart Period and Systolic Pressure in Humans. In Proceedings of the Computers in Cardiology, Chicago, IL, USA, 19–22 September 2004; IEEE: Piscataway, NJ, USA, 2004; pp. 277–280. [Google Scholar]
  7. Takalo, R.; Saul, J.P.; Korhonen, I. Comparison of Closed-Loop and Open-Loop Models in the Assessment of Cardiopulmonary and Baroreflex Gains. Methods Inf. Med. 2004, 43, 296–301. [Google Scholar] [CrossRef]
  8. Hytti, H.; Takalo, R.; Ihalainen, H. Tutorial on Multivariate Autoregressive Modelling. J. Clin. Monit. Comput. 2006, 20, 101–108. [Google Scholar] [CrossRef]
  9. Faes, L.; Erla, S.; Porta, A.; Nollo, G. A Framework for Assessing Frequency Domain Causality in Physiological Time Series with Instantaneous Effects. Philos. Trans. R. Soc. A Math. Phys. Eng. Sci. 2013, 371, 20110618. [Google Scholar] [CrossRef]
  10. Faes, L.; Nollo, G. Measuring Frequency Domain Granger Causality for Multiple Blocks of Interacting Time Series. Biol. Cybern. 2013, 107, 217–232. [Google Scholar] [CrossRef]
  11. Faes, L.; Erla, S.; Nollo, G. Block Partial Directed Coherence: A New Tool for the Structural Analysis of Brain Networks. Int. J. Bioelectromagn. 2012, 14, 162–166. [Google Scholar]
  12. Faes, L.; Erla, S.; Nollo, G. Measuring Connectivity in Linear Multivariate Processes: Definitions, Interpretation, and Practical Analysis. Comput. Math. Methods Med. 2012, 2012, 140513. [Google Scholar] [CrossRef]
  13. Seth, A.K. A MATLAB Toolbox for Granger Causal Connectivity Analysis. J. Neurosci. Methods 2010, 186, 262–273. [Google Scholar] [CrossRef]
  14. Seth, A.K. Granger Causal Connectivity Analysis: A MATLAB Toolbox; University of Sussex: Brighton, UK, 2011. [Google Scholar]
  15. Barnett, L.; Seth, A.K. The MVGC Multivariate Granger Causality Toolbox: A New Approach to Granger-Causal Inference. J. Neurosci. Methods 2014, 223, 50–68. [Google Scholar] [CrossRef] [PubMed]
  16. Chao-Ecija, A.; Dawid-Milner, M.S. BaroWavelet: An R-Based Tool for Dynamic Baroreflex Evaluation through Wavelet Analysis Techniques. Comput. Methods Programs Biomed. 2023, 242, 107758. [Google Scholar] [CrossRef] [PubMed]
  17. Farnè, M.; Montanari, A. A Bootstrap Method to Test Granger-Causality in the Frequency Domain. Comput. Econ. 2022, 59, 935–966. [Google Scholar] [CrossRef]
  18. Porta, A.; Furlan, R.; Rimoldi, O.; Pagani, M.; Malliani, A.; van de Borne, P. Quantifying the Strength of the Linear Causal Coupling in Closed Loop Interacting Cardiovascular Variability Signals. Biol. Cybern. 2002, 86, 241–251. [Google Scholar] [CrossRef]
  19. Faes, L.; Nollo, G. Multivariate Frequency Domain Analysis of Causal Interactions in Physiological Time Series. In Biomedical Engineering, Trends in Electronics, Communications and Software; InTech: Rijeka, Croatia, 2011; pp. 403–428. [Google Scholar]
  20. Percival, D.B.; Walden, A.T. The Discrete Wavelet Transform. In Wavelet Methods for Time Series Analysis; Cambridge University Press: Cambridge, UK, 2000; pp. 56–158. [Google Scholar]
  21. Percival, D.B.; Walden, A.T. The Maximal Overlap Discrete Wavelet Transform. In Wavelet Methods for Time Series Analysis; Cambridge University Press: Cambridge, UK, 2000; pp. 159–205. [Google Scholar]
  22. Percival, D.B.; Walden, A.T. The Discrete Wavelet Packet Transform. In Wavelet Methods for Time Series Analysis; Cambridge University Press: Cambridge, UK, 2000; pp. 206–254. [Google Scholar]
  23. Tzabazis, A.; Eisenried, A.; Yeomans, D.C.; Hyatt, M.I. V Wavelet Analysis of Heart Rate Variability: Impact of Wavelet Selection. Biomed. Signal. Process. Control 2018, 40, 220–225. [Google Scholar] [CrossRef]
  24. Quandt, V.I.; Pacola, E.R.; Pichorim, S.F.; Sovierzoski, M.A. Border Extension in the Wavelet Analysis of Lung Sounds. In World Congress on Medical Physics and Biomedical Engineering 26–31 May 2012, Beijing, China; Springer: Berlin/Heidelberg, Germany, 2013; pp. 597–600. [Google Scholar]
  25. Li, L.; Li, K.; Liu, C.; Liu, C. Comparison of Detrending Methods in Spectral Analysis of Heart Rate Variability. Res. J. Appl. Sci. Eng. Technol. 2011, 3, 1014–1021. [Google Scholar]
  26. Andrecut, M. Fast Time Series Detrending with Applications to Heart Rate Variability Analysis. Int. J. Mod. Phys. C 2019, 30, 1950069. [Google Scholar] [CrossRef]
  27. Yoo, C.S.; Yi, S.H. Effects of Detrending for Analysis of Heart Rate Variability and Applications to the Estimation of Depth of Anesthesia. J. Korean Phys. Soc. 2004, 44, 561. [Google Scholar] [CrossRef]
  28. Gebauer, J.E.; Adler, J. Using Shiny Apps for Statistical Analyses and Laboratory Workflows. J. Lab. Med. 2023, 47, 149–153. [Google Scholar] [CrossRef]
  29. Ding, M.; Bressler, S.; Yang, W.; Liang, H. Short-Window Spectral Analysis of Cortical Event-Related Potentials by Adaptive Multivariate Autoregressive Modeling: Data Preprocessing, Model Validation, and Variability Assessment. Biol. Cybern. 2000, 83, 35–45. [Google Scholar] [CrossRef] [PubMed]
  30. Chen, H.-K.; Hu, Y.-F.; Lin, S.-F. Methodological Considerations in Calculating Heart Rate Variability Based on Wearable Device Heart Rate Samples. Comput. Biol. Med. 2018, 102, 396–401. [Google Scholar] [CrossRef]
  31. Shibata, R. Selection of the Order of an Autoregressive Model by Akaike’s Information Criterion. Biometrika 1976, 63, 117. [Google Scholar] [CrossRef]
  32. Boardman, A.; Schlindwein, F.S.; Rocha, A.P.; Leite, A. A Study on the Optimum Order of Autoregressive Models for Heart Rate Variability. Physiol. Meas. 2002, 23, 325–336. [Google Scholar] [CrossRef] [PubMed]
  33. Bassani, T.; Bari, V.; Marchi, A.; Wu, M.A.; Baselli, G.; Citerio, G.; Beda, A.; de Abreu, M.G.; Güldner, A.; Guzzetti, S.; et al. Coherence Analysis Overestimates the Role of Baroreflex in Governing the Interactions between Heart Period and Systolic Arterial Pressure Variabilities during General Anesthesia. Auton. Neurosci. 2013, 178, 83–88. [Google Scholar] [CrossRef] [PubMed]
  34. Laude, D.; Elghozi, J.-L.; Girard, A.; Bellard, E.; Bouhaddi, M.; Castiglioni, P.; Cerutti, C.; Cividjian, A.; Rienzo, M.D.; Fortrat, J.-O.; et al. Comparison of Various Techniques Used to Estimate Spontaneous Baroreflex Sensitivity (the EuroBaVar Study). Am. J. Physiol.-Regul. Integr. Comp. Physiol. 2004, 286, R226–R231. [Google Scholar] [CrossRef]
  35. McLoone, V.; Ringwood, J.V. A System Identification Approach to Baroreflex Sensitivity Estimation. In Proceedings of the IET Irish Signals and Systems Conference (ISSC 2012), Maynooth, Ireland, 28–29 June 2012; Institution of Engineering and Technology: Stevenage, UK, 2012; pp. 301–306. [Google Scholar]
  36. Bari, V.; Vaini, E.; De Maria, B.; Cairo, B.; Pistuddi, V.; Ranucci, M.; Porta, A. Comparison of Different Strategies to Assess Cardiac Baroreflex Sensitivity Based on Transfer Function Technique in Patients Undergoing General Anesthesia. Annu. Int. Conf. IEEE Eng. Med. Biol. Soc. 2018, 2018, 2780–2783. [Google Scholar] [CrossRef]
  37. Dani, M.; Dirksen, A.; Taraborrelli, P.; Torocastro, M.; Panagopoulos, D.; Sutton, R.; Lim, P.B. Autonomic Dysfunction in “Long COVID”: Rationale, Physiology and Management Strategies. Clin. Med. 2021, 21, e63–e67. [Google Scholar] [CrossRef]
  38. Westerhof, B.E.; Gisolf, J.; Stok, W.J.; Wesseling, K.H.; Karemaker, J.M. Time-Domain Cross-Correlation Baroreflex Sensitivity: Performance on the EUROBAVAR Data Set. J. Hypertens. 2004, 22, 1371–1380. [Google Scholar] [CrossRef]
  39. Choi, Y.; Ko, S.; Sun, Y. Effect of Postural Changes on Baroreflex Sensitivity: A Study on the Eurobavar Data Set. In Proceedings of the 2006 Canadian Conference on Electrical and Computer Engineering, Ottawa, ON, Canada, 7–10 May 2006; IEEE: Piscataway, NJ, USA, July, 2006; pp. 110–114. [Google Scholar]
  40. Parati, G.; Castiglioni, P.; Faini, A.; Di Rienzo, M.; Mancia, G.; Barbieri, R.; Saul, J.P. Closed-Loop Cardiovascular Interactions and the Baroreflex Cardiac Arm: Modulations Over the 24 h and the Effect of Hypertension. Front. Physiol. 2019, 10, 477. [Google Scholar] [CrossRef]
  41. Chao-Écija, Á.; Carrasco-Gómez, D.; Dawid-Milner, M.S. Effectiveness of an R-Based Software to Detect Closed-Loop Cardio- Vascular Interactions and Baroreflex Impairment in Human subjects from the EUROBAVAR Data Set. J. Physiol. Biochem. 2022, 78, S34. [Google Scholar] [CrossRef]
Figure 1. Trend isolation process through a six-level decomposition with the MODWT. The coefficients shown belong to the original signal and its smoothed representation through approximation coefficients (black), as well as to each decomposition level from D1 to D6, which hold the detail coefficients obtained from the analysis (red).
Figure 1. Trend isolation process through a six-level decomposition with the MODWT. The coefficients shown belong to the original signal and its smoothed representation through approximation coefficients (black), as well as to each decomposition level from D1 to D6, which hold the detail coefficients obtained from the analysis (red).
Biology 12 01438 g001
Figure 2. Trend isolation process through the MODWT with an additional border handling strategy applied to the transform. The handling strategy extends the original IBI signal and creates an additional number of coefficients (blue).
Figure 2. Trend isolation process through the MODWT with an additional border handling strategy applied to the transform. The handling strategy extends the original IBI signal and creates an additional number of coefficients (blue).
Biology 12 01438 g002
Figure 3. Interface to upload and window cardiovascular data. A csv file containing the necessary data is uploaded and interpolated up to a sample frequency of 4 Hz. A time window is selected, and mean HR and SBP values from this window are reported. The data were obtained from a subject during a head-up tilt session.
Figure 3. Interface to upload and window cardiovascular data. A csv file containing the necessary data is uploaded and interpolated up to a sample frequency of 4 Hz. A time window is selected, and mean HR and SBP values from this window are reported. The data were obtained from a subject during a head-up tilt session.
Biology 12 01438 g003
Figure 4. Time-domain and frequency-domain changes in HRV due to the preprocessing algorithms available in CardioRVAR. (A) Non-detrended signal, with a sample frequency of 4 Hz, and its frequency-domain non-parametric and parametric spectra, with a significant very-low-frequency component. (B) Detrended signal after selecting a reference frequency of 0.04 Hz (cutoff: 0.03125 Hz, blue mark), accompanied by its non-parametric and parametric spectra, showing a mitigated very-low-frequency component. (C) Detrended signal after selecting a reference frequency of 0.07 Hz (cutoff: 0.0625 Hz, blue mark), with spectral densities showing a more mitigated very-low-frequency component, while also affecting part of the LF component. Yellow areas indicate ranges of possible reference frequencies associated with the last decomposition level, used to identify the cutoff frequency (blue marks) in each case. Green marks indicate cutoff frequencies (0.0625 Hz, 0.125 Hz) associated with the previous decomposition level. Red areas indicate frequency components below 0.04 Hz.
Figure 4. Time-domain and frequency-domain changes in HRV due to the preprocessing algorithms available in CardioRVAR. (A) Non-detrended signal, with a sample frequency of 4 Hz, and its frequency-domain non-parametric and parametric spectra, with a significant very-low-frequency component. (B) Detrended signal after selecting a reference frequency of 0.04 Hz (cutoff: 0.03125 Hz, blue mark), accompanied by its non-parametric and parametric spectra, showing a mitigated very-low-frequency component. (C) Detrended signal after selecting a reference frequency of 0.07 Hz (cutoff: 0.0625 Hz, blue mark), with spectral densities showing a more mitigated very-low-frequency component, while also affecting part of the LF component. Yellow areas indicate ranges of possible reference frequencies associated with the last decomposition level, used to identify the cutoff frequency (blue marks) in each case. Green marks indicate cutoff frequencies (0.0625 Hz, 0.125 Hz) associated with the previous decomposition level. Red areas indicate frequency components below 0.04 Hz.
Biology 12 01438 g004
Figure 5. Relative errors computed for each frequency between the frequency-domain non-parametric spectra of a raw IBI signal and its detrended version using the MODWT-based detrending algorithm with (A) the Haar wavelet and (B) the Daubechies 8 wavelet. Vertical lines indicate frequencies 0.04 Hz and 0.15 Hz.
Figure 5. Relative errors computed for each frequency between the frequency-domain non-parametric spectra of a raw IBI signal and its detrended version using the MODWT-based detrending algorithm with (A) the Haar wavelet and (B) the Daubechies 8 wavelet. Vertical lines indicate frequencies 0.04 Hz and 0.15 Hz.
Biology 12 01438 g005
Figure 6. Transfer functions reported by the software from patient during (A) head-up tilt and (B) post-tilt recovery. From left to right: closed-loop transfer function without zero-lagged interactions, closed-loop transfer function with zero-lagged interactions, and open-loop transfer function. Color code: LF band (green), HF band (yellow).
Figure 6. Transfer functions reported by the software from patient during (A) head-up tilt and (B) post-tilt recovery. From left to right: closed-loop transfer function without zero-lagged interactions, closed-loop transfer function with zero-lagged interactions, and open-loop transfer function. Color code: LF band (green), HF band (yellow).
Biology 12 01438 g006
Figure 7. Percentage of noise source contribution computed from a patient to the variability of (A) IBI before head-up tilt, (B) SBP before head-up tilt, (C) IBI during head-up tilt, and (D) SBP during head-up tilt. Color code: IBI noise (white), SBP noise (blue).
Figure 7. Percentage of noise source contribution computed from a patient to the variability of (A) IBI before head-up tilt, (B) SBP before head-up tilt, (C) IBI during head-up tilt, and (D) SBP during head-up tilt. Color code: IBI noise (white), SBP noise (blue).
Biology 12 01438 g007
Figure 8. Heart rate (red) and systolic blood pressure (blue) recordings obtained from (A) subject A, a healthy patient who exhibited a weak response during head-up tilt, and (B) subject B, who suffered from Postural Orthostatic Tachycardia Syndrome induced by long-COVID.
Figure 8. Heart rate (red) and systolic blood pressure (blue) recordings obtained from (A) subject A, a healthy patient who exhibited a weak response during head-up tilt, and (B) subject B, who suffered from Postural Orthostatic Tachycardia Syndrome induced by long-COVID.
Biology 12 01438 g008
Figure 9. Individual closed-loop BRS estimates computed through CardioRVARapp from the EUROBAVAR A series of subjects, and their distributions, obtained in (A) supine position, through the maximum coherence strategy; (B) supine position, through the coherence-thresholding strategy; (C) standing position, through the maximum coherence strategy; and (D) standing position, through the coherence-thresholding strategy. Blue arrows indicate subjects with missing estimates due to the coherence-thresholding strategy. Color code: HF band (black), LF band (white).
Figure 9. Individual closed-loop BRS estimates computed through CardioRVARapp from the EUROBAVAR A series of subjects, and their distributions, obtained in (A) supine position, through the maximum coherence strategy; (B) supine position, through the coherence-thresholding strategy; (C) standing position, through the maximum coherence strategy; and (D) standing position, through the coherence-thresholding strategy. Blue arrows indicate subjects with missing estimates due to the coherence-thresholding strategy. Color code: HF band (black), LF band (white).
Biology 12 01438 g009
Figure 10. Individual closed-loop BRS estimates computed through CardioRVARapp from the EUROBAVAR B series of subjects, and their distributions, obtained in (A) supine position, through the maximum coherence strategy; (B) supine position, through the coherence-thresholding strategy; (C) standing position, through the maximum coherence strategy; and (D) standing position, through the coherence-thresholding strategy. Red arrows indicate baroreflex-impaired subjects. Blue arrows indicate non-impaired subjects with missing estimates due to the coherence-thresholding strategy. Purple arrows indicate baroreflex-impaired subjects with missing estimates due to the coherence-thresholding strategy. Color code: HF band (black), LF band (white).
Figure 10. Individual closed-loop BRS estimates computed through CardioRVARapp from the EUROBAVAR B series of subjects, and their distributions, obtained in (A) supine position, through the maximum coherence strategy; (B) supine position, through the coherence-thresholding strategy; (C) standing position, through the maximum coherence strategy; and (D) standing position, through the coherence-thresholding strategy. Red arrows indicate baroreflex-impaired subjects. Blue arrows indicate non-impaired subjects with missing estimates due to the coherence-thresholding strategy. Purple arrows indicate baroreflex-impaired subjects with missing estimates due to the coherence-thresholding strategy. Color code: HF band (black), LF band (white).
Biology 12 01438 g010
Figure 11. Baroreflex sensitivity changes in closed-loop estimates computed by CardioRVARapp from EUROBAVAR during supine and standing positions in HF and LF bands, excluding the two impaired ones (n = 19), through (A) Gaussian-weighting strategy and (B) maximum coherence strategy. Significance: p < 0.01 (**), p < 0.001 (***).
Figure 11. Baroreflex sensitivity changes in closed-loop estimates computed by CardioRVARapp from EUROBAVAR during supine and standing positions in HF and LF bands, excluding the two impaired ones (n = 19), through (A) Gaussian-weighting strategy and (B) maximum coherence strategy. Significance: p < 0.01 (**), p < 0.001 (***).
Biology 12 01438 g011
Figure 12. Causal coherence flows from (A) HF band from IBI to SBP (dark green) and vice versa (light green) at both supine (left) and standing (right) positions, and (B) HF band from IBI to SBP (dark green) and vice versa (light green) at both supine (left) and standing (right) positions. The two impaired subjects were excluded from the analysis (n = 19). Significance: p < 0.001 (***).
Figure 12. Causal coherence flows from (A) HF band from IBI to SBP (dark green) and vice versa (light green) at both supine (left) and standing (right) positions, and (B) HF band from IBI to SBP (dark green) and vice versa (light green) at both supine (left) and standing (right) positions. The two impaired subjects were excluded from the analysis (n = 19). Significance: p < 0.001 (***).
Biology 12 01438 g012
Table 1. Estimates from subjects A and B during the different periods of the head-up tilt test returned by CardioRVAR, using its graphical interface. The displayed results were obtained through the following estimation methods and criteria: coherence threshold (CT), weighted average (WA), and maximum coherence (MC).
Table 1. Estimates from subjects A and B during the different periods of the head-up tilt test returned by CardioRVAR, using its graphical interface. The displayed results were obtained through the following estimation methods and criteria: coherence threshold (CT), weighted average (WA), and maximum coherence (MC).
Subject ASubject B
VariablePre-Tilt IntervalTilt IntervalPost-Tilt IntervalPre-Tilt IntervalTilt IntervalPost-Tilt Interval
HR (bpm)48.2754.0349.4278.42109.7469.75
SBP (mmHg)102.12109.15111.65125.84121.62120.95
CT-HF αc
(ms/mmHg)
26.5411.5735.9013.30N/A 13.60
WA-HF αc
(ms/mmHg)
24.139.0531.569.541.7612.81
MC-HF αc
(ms/mmHg)
27.3412.5036.3313.101.7816.33
CT-LF αc
(ms/mmHg)
6.951.74N/A 11.783.9817.88
WA-LF αc
(ms/mmHg)
7.334.5917.4111.283.8117.78
MC-LF αc
(ms/mmHg)
7.021.731.6312.254.1116.77
Squared coherence was below 0.5 n.u.
Table 2. Comparison of estimates obtained from the tool between normotensive and hypertensive subjects using two strategies for the computation of the BRS.
Table 2. Comparison of estimates obtained from the tool between normotensive and hypertensive subjects using two strategies for the computation of the BRS.
PositionBandEstimate TypeNormotensive
(n = 5)
Hypertensive
(n = 7)
p Value
Supine restHFWeighted-averaged9.02 ± 3.882.03 ± 0.45p < 0.01
Estimate at maximum coherence10.99 ± 4.143.10 ± 0.75p < 0.05
LFWeighted-averaged5.94 ± 1.382.25 ± 0.39p = 0.054
Estimate at maximum coherence6.19 ± 1.321.69 ± 0.37p < 0.05
TiltHFWeighted-averaged4.34 ± 1.391.27 ± 0.29p = 0.091
Estimate at maximum coherence5.01 ± 1.951.46 ± 0.21p = 0.143
LFWeighted-averaged4.90 ± 0.642.06 ± 0.22p < 0.01
Estimate at maximum coherence4.69 ± 0.961.66 ± 0.23p < 0.05
Data are presented as means ± standard errors of the mean (SEM). Normality was first tested with the Shapiro–Wilk test. Significance was computed with the unpaired t-test or Wilcoxon test. Significant p values (p < 0.05) are shown in bold.
Table 3. Supine and standing position BRS estimates computed by CardioRVARapp through Gaussian-weighting and maximum coherence strategies from EUROBAVAR subjects, excluding the two impaired ones (n = 19).
Table 3. Supine and standing position BRS estimates computed by CardioRVARapp through Gaussian-weighting and maximum coherence strategies from EUROBAVAR subjects, excluding the two impaired ones (n = 19).
Closed-LoopOpen-Loop
(Type II)
Open-Loop
(Type I)
BandMethodSupine
(ms/mmHg)
Standing
(ms/mmHg)
p ValueSupine
(ms/mmHg)
Standing
(ms/mmHg)
p ValueSupine
(ms/mmHg)
Standing
(ms/mmHg)
p Value
HFWeighted average11.06 ± 2.463.54 ± 0.54p < 0.00113.82 ± 2.925.03 ± 0.81p < 0.00120.79 ± 3.747.82 ± 1.27p < 0.001
Maximum coherence13.03 ± 2.474.84 ± 0.79p < 0.00116.07 ± 2.686.40 ± 1.07p < 0.00117.40 ± 2.927.51 ± 1.38p < 0.001
LFWeighted average8.12 ± 1.724.12 ± 0.55p < 0.0019.23 ± 2.255.12 ± 0.77p < 0.00112.72 ± 2.757.12 ± 0.91p < 0.001
Maximum coherence7.92 ± 1.504.06 ± 0.54p < 0.0110.48 ± 2.045.42 ± 0.68p < 0.0112.43 ± 2.256.41 ± 0.77p < 0.01
Data are presented as means ± standard errors of the mean (SEM). Normality was first tested with the Shapiro–Wilk test. Significance was computed from t-test or Wilcoxon test for paired samples. Significant p values (p < 0.05) are shown in bold.
Table 4. Supine and standing position causal coherence estimates computed by CardioRVARapp from EUROBAVAR subjects, excluding the two impaired ones (n = 19).
Table 4. Supine and standing position causal coherence estimates computed by CardioRVARapp from EUROBAVAR subjects, excluding the two impaired ones (n = 19).
PositionBand C o h 2 S B P I B I (n.u.) C o h 2 I B I S B P (n.u.) p Value
SupineHF0.23 ± 0.020.21 ± 0.02p = 0.644
LF0.19 ± 0.030.54 ± 0.04p < 0.001
StandingHF0.21 ± 0.030.19 ± 0.02p = 0.510
LF0.29 ± 0.040.32 ± 0.03p = 0.606
Data are presented as means ± standard errors of the mean (SEM). Normality was first tested with the Shapiro–Wilk test. Significance was computed from t-test for paired samples. Significant p values (p < 0.05) are shown in bold.
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Chao-Écija, A.; López-González, M.V.; Dawid-Milner, M.S. CardioRVAR: A New R Package and Shiny Application for the Evaluation of Closed-Loop Cardiovascular Interactions. Biology 2023, 12, 1438. https://doi.org/10.3390/biology12111438

AMA Style

Chao-Écija A, López-González MV, Dawid-Milner MS. CardioRVAR: A New R Package and Shiny Application for the Evaluation of Closed-Loop Cardiovascular Interactions. Biology. 2023; 12(11):1438. https://doi.org/10.3390/biology12111438

Chicago/Turabian Style

Chao-Écija, Alvaro, Manuel Víctor López-González, and Marc Stefan Dawid-Milner. 2023. "CardioRVAR: A New R Package and Shiny Application for the Evaluation of Closed-Loop Cardiovascular Interactions" Biology 12, no. 11: 1438. https://doi.org/10.3390/biology12111438

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop