Introduction of Application of Gini Coefficient to Heart Rate Variability Spectrum for Mental Stress Evaluation

Background The Gini coefficient is a statistical tool generally used by economists to quantify income inequality. However, it can be applied to any kind of data with unequal distribution, including heart rate variability (HRV). Objectives To assess the application of the Gini coefficient to measure inequality in power spectral density of RR intervals, and to use this application as a psychophysiological indicator of mental stress. Methods Thirteen healthy subjects (19 ± 1.5 years) participated in this study, and their RR intervals were obtained by electrocardiogram during rest (five minutes) and during mental stress (arithmetic challenge; five minutes). These RR intervals were used to obtain the estimates of power spectral densities (PSD). The limits for the PSD bands were defined from 0.15 to 0.40 Hz for high frequency band (HF), from 0.04 to 0.15 Hz for low frequency band (LF), from 0.04 to 0.085 Hz for first low frequency sub-band (LF1) and from 0.085 to 0.15 Hz for second low frequency sub-band (LF2). The spectral Gini coefficient (SpG) was proposed to measure the inequality in the power distribution of the RR intervals in each of above-mentioned HRV bands. SpG from each band was compared with its respective traditional index of HRV during the conditions of rest and mental stress. All the differences were considered statistically significant for p < 0.05. Results There was a significant decrease in HF power (p = 0.046), as well as significant increases in heart rate (p = 0.004), LF power (p = 0.033), LF2 power (p = 0.019) and LF/HF (p = 0.002) during mental stress. There was also a significant increase in SpG(LF) (p = 0.009) and SpG(LF2) (p = 0.033) during mental stress. Coefficient of variation showed SpG has more homogeneity compared to the traditional index of HRV during mental stress. Conclusions This pilot study suggested that spectral inequality of Heart Rate Variability analyzed using the Gini coefficient seems to be an independent and homogeneous psychophysiological indicator of mental stress. Also, HR, LF/HF, SpG(LF) of HRV are possibly important, reliable and valid indicators of mental stress.


Introduction
The Gini coefficient is a statistical tool typically used in economics to measure income inequality. However, it can be applied to any data with an unequal distribution, including Heart Rate Variability (HRV). HRV is the spectrum of time interval between successive heartbeats (RR interval) over a specific period. This study proposes a novel application of the Gini coefficient to measure the inequality of the power spectral density of RR intervals.
Physical or mental imbalance caused by noxious stimuli can induce stress to normal homeostasis. If the stress on the system becomes chronic, the sympathetic nervous system stays activated, which can cause physical, psychological, and behavioral abnormalities. 1 Sympathetic nervous system sensitivity to mental stress increases over time and it can increase the risk of future cardiovascular diseases. 2 HRV measurement has been adopted as a non-invasive and relatively easy method for objective assessment of the severity of stress. 3 It is a physiological phenomenon of variation in the time interval between heartbeats (RR interval) and is commonly used as a measure of autonomic nervous system activity. [4][5][6][7] Power spectral density (PSD) describes the transformation of periodic oscillations of the heart-rate signals into different frequencies. This transformation gives numerical values about their relative intensity. 8,9 Spectral methods produce a decomposition of total variation of a data series into its frequency components, which can be expressed in the form of a spectral density function that depicts spectral power as a function of frequency. 10 A standard for HRV measurement and interpretation of frequency domain variables was published in 1996, and most subsequent studies are based on it. 4,9 These traditional HRV indices in frequency domain variables include very low frequency [0.0033-0.04 Hz], HF [0. 15-0.4 Hz] and LF [0.04-0. 15 Hz]. HF has been linked to the parasympathetic influence on the heart, while LF is modulated by baroreflex activity and has been linked to both sympathetic and parasympathetic activity. 4,6,7,11,12 The power of traditional HRV indices in different bands changes by increasing or decreasing sympathetic or vagal modulation. However, it is unknown how equally this power in each frequency band is distributed during rest. It is also unknown how this power distribution gets affected with changes in sympathetic or parasympathetic modulation. To our best knowledge, the inequality in power distribution of HRV spectrum has not been measured before. Therefore, the present study aims 1) to apply the Gini coefficient to power spectral density of HRV to measure the inequality of power distribution of frequency bands; 2) to compare the inequality in power spectrums of HRV signals during rest versus under mental stress; 3) to evaluate the Gini coefficient as a psychophysiological indicator of mental stress in comparison to traditional HRV indices.

Study population
A total of 13 healthy subjects (7 females, 6 males), age 19 ± 1.5 years, BMI 22.3 ± 1.3 kg/m 2 , participated in this crossover study. An a-priori power analysis found that this number of participants would yield 80% power at an alpha level of 0.05. All the subjects were non-smokers and had no history of heart disease, systemic hypertension or any other disease. Participants did not take any medications, drugs or alcohol for 12 hours preceding the experiment and were advised not to drink any caffeinated beverages on the morning of the study. Prior to participation, subjects signed an informed consent. Study procedures were in accordance with the Declaration of Helsinki and the study protocol was approved by the Ethics Committee of the Medical University of Santiago de Cuba.
Experiments were performed in a quiet environment, between 9 a.m. and 12:30 p.m.. ECGs were taken in a sitting position, during rest and during arithmetic mental stress. After attachment of the electrodes, every subject relaxed for 10 min. ECG recordings were obtained during rest with spontaneous breathing for 5 min. Immediately afterwards, subjects performed a mental arithmetic task for 5 min. [13][14][15] The mental arithmetic task is one of the most efficient stimuli for inducing mental stress. [16][17][18] Briefly, subjects subtracted 7, starting from 1000. They were instructed to subtract as accurately as possible. For a single subtraction, time allowed was 5s and was signaled by a sound. Subjects said the result aloud and after each answer, subjects received verbal confirmation ("right" or "wrong"). They continued successive subtraction, even when the result was wrong. Aside from verbalization of the answers, subjects did not talk during the mental arithmetic challenge.

Signal acquisition and processing
A PowerLab Acquisition System 8 ® (ADInstruments) was used to collect the ECG recordings, with a sampling rate of 1000 Hz. A standard Lead II was used for ECG measurement. The Sabarimalai-Manikandan's 19 algorithm was used to detect the QRS complexes in the ECG signal, from which RR intervals were obtained. Pre-processing of RR series data was required before HRV analysis in order to reduce analytic errors. The standard deviation filter with percentage filter, with value of 20% from the previous interval, were used to detect ectopic intervals. 20 Cubic Spline Replacement was employed to replace ectopic intervals using cubic spline interpolation. 21 Finally, in other analysis of ECG signals, an ECG-derived Respiration Rate (EDR) was computed from raw ECG throughout the procedure via a built-in algorithm of Kubios HRV Premium ® 3.0.2 software. The algorithm examined the alterations in the amplitude of the R-peak caused by chest movements during each respiratory cycle. Under stationary conditions (i.e., short-term registrations), the EDR is considered a reliable index of respiratory rates. 22 A previous study found a reasonable agreement between EDR and a reference respiratory rate derived from nasal/oral airflow. 23 Heart rate variability analysis Using the algorithm described by Berger, 24 the RR interval sequence was transformed into temporal RR sequence. Pre-processed temporal 5-min RR series were subjected to spectral analysis using the Welch periodogram method to obtain the estimates of power spectral densities (PSD). A total of 2048 samples (5-min RR series) were subjected to computation through the Welch modified periodogram with a Hann window, using segments of 512 samples and overlapping periods of 256 samples. The limits for the spectral HRV bands were delimited from 0.15 to 0.40 Hz for the HF, from 0.04 to 0.15 Hz for the LF, from 0.04 to 0.085 Hz for the LF1 and from 0.085 to 0.15 Hz for the LF2. Absolute PSD were calculated as the integral of each one-sided quadratic spectrogram in the frequency ranges previously defined.

Proposed Spectral Gini HRV Indices
The Gini coefficient is typically used by economists to measure income inequality. If the income level of the th [ = 1, 2. . . ] house is , the Gini coefficient is calculated using the following equation: 25 If the incomes of all houses are equal, that is, 1 = 2 = ⋅⋅ ⋅ = , the Gini coefficient becomes 0. Additionally, when only one house has income, that is, 1 > 2 = ⋅⋅⋅ = = 0, the income inequality is maximal and the Gini coefficient is equal to 1. 25,,26 Kyung-Jin You et al., 26 in 2016, have proposed the Gini coefficient to quantify the inequality in the power spectrum in the range of interest ( -Hz) in electroencephalography for quantifying the depth of consciousness during anesthesia. Applying this to HRV, if each frequency of the power spectrum of the RR intervals is considered as an individual house and the power of the corresponding frequency is considered as the house income, it would be possible to quantify the spectral inequality in terms of the Gini coefficient. Therefore, the Spectral Gini coefficient (SpG) is expressed as: The SpG can measure the inequality in the spectral powers of the RR intervals in each spectral HRV bands employed.

Statistical analysis
All values were expressed as Mean (X), Standard Deviation (SD) and Coefficient of Variation (CV %), Median [*] and Interquartile Range [¥]. All differences were considered statistically significant for p < 0.05.
The Wilcoxon Signed-Rank Test (non-parametric test) for two related samples was used to compare rest versus mental stress. Effect Size with Gates' delta was calculated and values above 0.80 were adopted with high magnitude. 27 In order to verify the association between traditional and Spectral Gini indices of HRV during mental stress and rest, Pearson's correlation was applied to the data with normal distribution, or Spearman's correlation, for the ones that did not accept this distribution. The normality of the data was initially determined using the Shapiro-Wilk test. Principal Component Analysis (PCA) is a technique to reduce the dimensionality of data consisting of correlated variables while capturing the bulk of variation present in the data. 28 There are as many principal components (PCs) as there are original variables. Each PC is a linear combination of the original variables with a set of weights called "loadings", which reflect the correlations between PCs and original variables. PC1 is the directional vector representing the best fit for data cloud. PC2 is the directional vector orthogonal to PC1 that provides the best fit for residual variability in the data, and so on. PCs are mutually uncorrelated. Effective dimensionality reduction is achieved when the first few (dominant) PCs capture most of the variation present in the data. Useful insights on the interrelationship between original variables can be obtained when the dominant PCs have substantive interpretations. The efficacy of the traditional and Spectral Gini Indices of HRV were defined by the Receiver Operating Characteristic (ROC) curve through Sensitivity, Specificity, Area Under Curve and its respective p value were used with Cutoff Points between rest and mental stress set by Youden Index.
All the statistical and mathematical calculations, as well as the processing of the signals, were performed using the Matlab 2012b software. Table 1 describes values of traditional and Spectral Gini Indices of HRV at rest and during mental stress. There was a significant decrease in HF (p = 0.046), a significant increase in the heart rate (p = 0.004), LF/HF (p = 0.002), LF (p = 0.033) and LF2 (p = 0.019) during mental stress, compared to rest. A significant increase in SpG(LF) (p = 0.009) and SpG(LF2) (p = 0.033) was observed. Coefficient of Variation analysis showed that Spectral Gini Indices are more homogeneous than traditional Indices of HRV.

Results
The correlation values between traditional and Spectral Gini Indices of HRV during rest and mental stress are shown in Table 2. During rest, there were high correlations between the HR and the SpG(LF1) (r = 0.721; p = 0.01) and between SpG(LF) and SpG(LF2) (r=0.829; p = 0.01), good correlations between LF and SpG(LF2) (r = 0.645; 0.05), and between LF2 and SpG(LF2) (r = 0.628; 0.05). During mental stress, there was a good correlation between SpG(LF) and SpG(LF2) (r = 0.682; 0.05). Table 3 represent Principal Component Analysis (PCA) of Traditional and Spectral Gini Indices of Heart Rate Variability during rest and mental stress.

Figure 1 and
The PCA helps to reduce the multiple characteristics or variables of a sample to a few dimensions (in this case, only two dimensions). It can be explained as trying to reduce twelve variables of an object to two values or characteristics and to determine which out of these twelve variables are the most robust for those two characteristics (two dimensions), which allow a better study of the object of interest. The important variables for each dimension are those that are higher than 1 or lower than -1. On dimension 1, the variables LF (1. With respect to Figure 1, the relationship between the variables is given by the cosine of the angle formed by each vector representing that specific variable. The more acute the angle, which is to say that it has a tendency to 0, the higher will be correlation, and if the vectors form a 90 degree angle, the variables will not be correlated. On the other hand, if they form an angle of 180 degrees, correlation is inverse. In dimension 2, the vectors of the variables HR, LF/HF and SpG LF form an angle close to 180 with the EDR and therefore, HR, LF/HF and SpG LF are negatively correlated with EDR. The size of the vector is the strength of that variable in that dimension.

Discussion
The present study aimed 1) to apply the Gini coefficient to power spectral densities of HRV to measure the inequality in distribution of frequency bands; 2) to compare the inequality in power spectrum of HRV signals during rest versus under mental stress; 3) to evaluate the Gini coefficient as a psychophysiological indicator of mental stress in comparison to traditional HRV indices.
In the present study, the traditional indices of HRV during mental stress showed expected results of significant increase in LF power and increase in LF/HF ratio, along with significant decrease in HF power. HRV is a reliable tool to measure psychophysiological stress 29 and the present results shows significant changes in HRV indices compared to rest. To the best of our knowledge, this is the first study to apply the Gini coefficient to power spectrums of HRV signal/RR intervals to measure inequality in distribution of power. Conceptually, a Gini coefficient of zero means that the power is distributed equally for all frequencies within a spectral bandwidth. In contrast, a Gini coefficient of 1 suggests that there is a single frequency with the most power within a specific spectral bandwidth, and all other frequencies in the bandwidth have no power. In other words, increase in the Gini coefficient value suggests that there are few frequencies with the most power within that frequency band compared to before. The results showed that there was a significant increase in SpG(LF) during mental stress compared to rest, meaning that during mental stress, not only there was an increase in total power in LF, but also the total power distribution became more unequal and certain frequencies gained the most power. It is noteworthy that the LF2 sub-band (0.085-0.15 Hz) showed increased inequality, as changes in SpG(LF) and  SpG(LF2) were significant but not for SpG(LF1) during mental stress. It should also be noted that the traditional HRV index showed a significant decrease in HF power during mental stress, but the decrease in SpG(HF) was not significant. These data suggest that there was decrease in power in the HF band, but the distribution of power within the HF band remained similar during rest and mental stress.
The coefficient of variation showed that, in comparison to traditional HRV indices, Gini spectral indices are homogeneous (see Table 1), meaning that the numeric values of changes in distribution of power during mental stress are located closer to the center (mean) and do not have high SD values like traditional indices. Pearson Correlation (and Spearman's correlation) Tests revealed poor correlation values between traditional and Spectral Gini Indices during mental stress, even though LF and LF2 of traditional HRV index showed good correlation with SpG (LF2) at rest. This indicated that Gini values are independent of traditional HRV indices and contribute to the additional information not reported until now.

Principal Component Analysis of traditional and Spectral
Gini indices helps to reduce the multiple characteristics or variables of a sample (HRV) to a few dimensions (in this case, only two dimensions). It can be explained as trying to reduce twelve variables of an object to two values or characteristics and to determine which out of these twelve variables are the most robust for those two characteristics (two dimensions), which allow a better study of the object of interest. Dimension 2 is what differentiates the state of stress (green arrow on the figure, which tends to go upward) from the state of rest (red arrow on the figure, which tends to go below). Therefore, even though LF and HF have values >1 on Dimension 1, the variables with high load such as HR,LF/HF, SpG LF and SpG LF2 from Dimension 2 are considered physiologically and clinically more important as state indicators.
ROC curve was produced in order to evaluate the efficacy of Spectral Gini indices as an evaluator of mental stress. The cutoff points of the different indicators in the differentiation of the psychophysiological states, obtained from the Youden Index of the ROC curve, can be observed. However, it stands out how the HR (p = 0.001) the LF/HF (p = 0.001) and the SpG (LF) (p = 0.011) constituted the most optimal (ROC model) and effective indicators in the discrimination between rest and mental stress with the best values of sensitivity, specificity, Youden Index and area under the curve (p < 0.05).
The results shown on Table 4 are consistent with the results in Table 1, Figure 1 and Table 3, suggesting that HR; LF/HF and SpG LF were highlighted in the discrimination of the states of rest and stress.
The significant increase in LF and SpG(LF) power during mental stress allows discussion on the contributing factors for LF power. It is generally accepted that the HF component  is a reflex of the parasympathetic activity, and that the LF and LF/HF components are a reflex of both sympathetic and parasympathetic activity. 4 Breathing rate can influence HRV variables noticeably. 14, 30 Bernardi et al. 14 have further reported that regardless of the amount of stress involved in the mental task, low breathing rate usually contributes to increase in LF power of HRV. Although there was a decrease in breathing rate during stress compared to rest in the present study, the EDR was 0.21 ± 0.04 Hz or 12.6 ± 0.24 br/min, which is not within the LF components in the RR power spectrum.
In other words, in the present study, respiration rate was not responsible for increased LF power during mental stress.
There are few studies examining the contributing factors to LF power of HRV in depth. In their recent study, Roach et al. 31 reported that 75% of the contribution to LF power comes from fluctuations called ripples, and these ripples are probably due to arterial baroreceptor functions. Reyes del Paso et al. 32 have showed a strong association between baroreflex activity and mental stress. Vaschillo et al. 33 have investigated the subdivision of LF in two separate components in young binge drinkers and suggested that these two divisions functionally indicate two distinct physiological parameters. LF1 represents vascular tone baroreflex and LF2 represents heart rate baroreflex activity.
As noted earlier, data analysis from the current study showed increased LF power and decreased HF power during mental stress, along with increased SpG(LF) and SpG(LF2). It is possible that, under stress, a healthy cardiovascular system generates more LF oscillations, especially with power mostly around 0.1Hz frequencies, to regain homeostasis. This possibility is supported by Bates et al., 34 who evaluated real-time changes in RR interval spectrum in response to placebo and alcohol. Bates et al. 34 suggested that under alcohol or other adverse conditions, one of the main adaptations includes maintaining low frequency oscillations even at the expense of high frequency oscillations. This can also explain the lack of changes in SpG(HF) under mental stress. That study also suggested that low frequency oscillations are useful to generate resonance for better adaptation, and 0.1 Hz is one of several resonance frequencies. The current study supports significant increase in LF subdivision during mental stress, and future studies are recommended to investigate the association of 0.1 Hz frequency to arterial baroreflex activity for better understanding of the mechanism of physiological adaptations during mental stress.

References Conclusions
This study successfully applied Gini coefficient to power spectral densities of HRV to measure the inequality in distribution of frequency bands.
These results suggest that during stress (arithmetic challenge), compared to rest, not only total power of low frequency band increases, but the total power distribution becomes more unequal.
Spectral inequalities of heart rate variability analyzed from the Gini coefficient seem to be independent and homogeneous indicators of psychophysiological mental stress compared to traditional indices of HRV as per this pilot study.
Out of traditional and spectral Gini indices of HRV, HR, LF/HF, SpG (LF) seems to be valid and reliable tools as indicators of stress, and this study provides cutoff values for these variables to discriminate the states of stress and rest.

Study limitations
Among the limitations of this study, the small sample size can be cited. This is a pilot study on Gini coefficient application to HRV spectrum, therefore more studies with larger sample sizes are recommended for better understanding and interpretation of inequalities in power spectral density of RR intervals.
In addition, a mental arithmetic challenge was used to induce mental stress. Although this method is considered valid and reliable, results can possibly be varied under different circumstances, as mental stress is a complex and dynamic phenomenon.
Finally, HRV can be influenced by hormones depending on the menstrual phase in female participants. Although the menstrual phase was not monitored, data for both conditions (rest and mental stress) were collected on the same day in order to minimize baseline variability.

Potential Conflict of Interest
No potential conflict of interest relevant to this article was reported.

Sources of Funding
There were no external funding sources for this study.

Study Association
This study is not associated with any thesis or dissertation work.

Ethical approval and informed consent
This study was approved by the Medical University of Santiago de Cuba Ethics Committee under protocol number 22/2017. All procedures involved in this study are in accordance with the 1975 Helsinki Declaration, updated in 2013. Informed consent was obtained from all participants included in the study.