Measurement of respiratory rate using wearable devices and applications to COVID-19 detection

We show that heart rate enabled wearable devices can be used to measure respiratory rate. Respiration modulates the heart rate creating excess power in the heart rate variability at a frequency equal to the respiratory rate, a phenomenon known as respiratory sinus arrhythmia. We isolate this component from the power spectral density of the heart beat interval time series, and show that the respiratory rate thus estimated is in good agreement with a validation dataset acquired from sleep studies (root mean squared error = 0.648 min−1, mean absolute error = 0.46 min−1, mean absolute percentage error = 3%). We use this respiratory rate algorithm to illuminate two potential applications (a) understanding the distribution of nocturnal respiratory rate as a function of age and sex, and (b) examining changes in longitudinal nocturnal respiratory rate due to a respiratory infection such as COVID-19. 90% of respiratory rate values for healthy adults fall within the range 11.8−19.2 min−1 with a mean value of 15.4 min−1. Respiratory rate is shown to increase with nocturnal heart rate. It also varies with BMI, reaching a minimum at 25 kg/m2, and increasing for lower and higher BMI. The respiratory rate decreases slightly with age and is higher in females compared to males for age <50 years, with no difference between females and males thereafter. The 90% range for the coefficient of variation in a 14 day period for females (males) varies from 2.3–9.2% (2.3−9.5%) for ages 20−24 yr, to 2.5−16.8% (2.7−21.7%) for ages 65−69 yr. We show that respiratory rate is often elevated in subjects diagnosed with COVID-19. In a 7 day window from D−1 to D+5 (where D0 is the date when symptoms first present, for symptomatic individuals, and the test date for asymptomatic cases), we find that 36.4% (23.7%) of symptomatic (asymptomatic) individuals had at least one measurement of respiratory rate 3 min−1 higher than the regular rate.


Isolating the signal 120
To begin, we assign reasonable values to f 1 and f 2 , which will be refined in subsequent 121 iterations. We initialize f 1 = f min and f 2 = 0.333 Hz (corresponding to a respiratory rate 122 of 20 min 1 ). In practice, the choice of f 1 and f 2 are determined by the expected range of 123 respiratory rates in the population under study. Signal estimation is performed using the 124 following steps: 125 1. The power spectrum is modeled as described earlier, and parameterized by the vari-126 ables (c 1 , c 2 , c 3 , c 4 , p 1 , p 2 , p 3 , p 4 ). 127 2. The background function is subtracted from the data to obtain the residuals. The 128 residuals are low pass filtered (we use a median filter of size 3) to reduce noise, and 129 interpolated (we use a cubic spline) to maintain the original frequency resolution. 3. The peak of the residuals is identified as A RSA , and the frequency corresponding to 131 the maximum value = f RSA . Assuming a gaussian distribution for the RSA feature, 132 we identify a frequency f < f RSA such that A(f ) = 0.6065A RSA , as well as a 133 frequency f + > f RSA such that A(f + ) = 0.6065A RSA . The mean of these two values 134 f resp = 0.5 ⇥ (f + + f ) is identified as the mean respiratory frequency. The standard 135 deviation is resp = 0.5 ⇥ (f + f ). The mean µ noise and standard deviation noise of 136 the residuals from f 0 to f min are calculated. The signal-to-noise ratio SN R is defined 137 as SN R = (A RSA µ noise ) / noise . 138 4. f 1 is redefined as f resp 3 resp , and f 2 is set to f resp + 3 resp .

139
Steps 1-4 are repeated until either successive estimates of f resp agree to within 1%, or 5 140 iterations are completed. We restrict our range of respiratory rates to between 10 min 1 to 141 26 min 1 . Frequencies much higher than 26 min 1 are hard to resolve due to the rapid fall-o↵ 142 of the power spectral density with frequency, while resonances at frequencies lower than 10 143 min 1 may be confused with Mayer wave oscillations [27]. The values of (f resp , resp , SNR) 144 are stored for each individual, for each day, provided SNR 2.5. Fig. 1(b) shows the 145 residuals and estimation of the RSA feature. Also shown is a gaussian with mean f resp and 146 standard deviation resp . 147 7 . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity. (which was not certified by peer review) The copyright holder for this preprint this version posted May 18, 2021. ;https://doi.org/10.1101https://doi.org/10. /2021 ical approach: The respiratory rate measurement for any given day for each individual is 149 treated as a random variable drawn from a gaussian distribution with mean f resp and stan-150 dard deviation resp . We randomly choose 100 samples from this distribution for each day.

151
The mean and standard deviation over all samples is then computed. We follow the same 152 process for averages involving multiple subjects.

153
C. Validation of estimated respiratory rate data with ground truth measurements 154 We obtained 52 measurements of air flow data, from 28 individuals through polysomnog-155 raphy (PSG), or a home sleep test (HST). Data were collected from 1 to 3 nights for each 156 participant, with devices on either one or both wrists (data from the two experiments were 157 combined, see Table S1 in the Supplementary Text for details). Data from the air flow 158 sensor were band pass filtered with a fourth order Butterworth filter to retain frequencies 159 between 10 min 1 -30 min 1 . The data were then analyzed with the help of a spectral peak 160 detection algorithm with a window size of 51.2 s and a step size of 6.4 s. The median of all 161 respiratory rate measurements over the night is computed, and serves as the true respiratory 162 rate.
163 Fig. 2 shows the comparison between the true respiratory rate and the rate estimated from 164 the peak of the heart beat interval power spectral density. Plot (a) shows 52 measurements 165 in the range (10 min 1 , 26 min 1 ) with SNR 2.5, obtained from 28 individuals with apnea-166 hypopnea index < 30. The Pearson correlation coe cient r = 0.9515. Plot (b) shows the 167 Bland-Altman plot of the di↵erence in measurements (predicted value -true value) plotted 168 against the average of the two. The bias (mean of the di↵erence between predicted and true 169 values) is 0.244 min 1 ( 1.67%), and the root mean squared error is 0.648 min 1 (4.2%).

170
The mean absolute error is found to be 0.460 min 1 , and the mean absolute percentage error 171 = 3.0%. CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity. (which was not certified by peer review) 16.1 ± 2.0 min 1 in non-REM sleep to 17.9 ± 2.7 min 1 in REM sleep (p < 0.05). Ref.

193
[34] also found a statistically significant di↵erence in respiratory rate among sleep stages 194 (p < 0.001), with REM sleep having the highest rate (p < 0.01). 195 We estimated the probability of the algorithm taking 0,1,2,3,4, and 5 iterations to estimate 196 the respiratory rate, using a subset of 1,000 randomly selected individuals on one night of 197 data (0 iterations means there was either no data, or the signal-to-noise ratio was found to 198 be too low for a reliable estimate. 14.6% of measurements had 0 iterations, i.e. no result 199 with deep sleep data, 6.1% of measurements had no result with light sleep data, and 2.6% . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity.

(which was not certified by peer review)
The copyright holder for this preprint this version posted May 18, 2021. For ages > 50 yr, we find r = 0.031( 0.043) for females (males).

221
Plot (b) shows the coe cient of variance (CoV) (ratio of standard deviation to the mean) 222 measured over a 14 day period, and only considering subjects with 10 or more nights of data.

223
The CoV increases with age, with a Pearson r correlation coe cient of 0.132 (0.172) for 224 females (males). The CoV varies from 4.65% (4.98%) in the age range 20 yr -25 yr to 6.14% 225 (7.41%) in the age range 65 yr -69 yr for females (males). The di↵erence between male and 226 female participants is most significant above age 60 yr (p value < 0.001).

227
The dependence of respiratory rate with BMI (measured in kg/m 2 ) is shown in Fig. 5(a).

228
The bin size in BMI = 1 and the error bars represent the standard error of the mean. series about the minimum, we find that the mean respiratory rate R measured in min 1 may 233 be expressed as: The variation of respiratory rate with nocturnal heart rate is shown in Fig. 5(b). The 237 heart rate in beats per minute (bpm) is measured in non-REM sleep. The red curve is for all 238 10 . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity.

(which was not certified by peer review)
The copyright holder for this preprint this version posted May 18, 2021. ; https://doi.org/10.1101/2021.05.15.21257200 doi: medRxiv preprint individuals, while the black and green curves are plotted for female and male participants 239 respectively. The mean respiratory rate (for all participants) increases with increase in heart 240 rate, with a Pearson r correlation of 0.154. It is possible to model the mean respiratory 241 rate R (measured in min 1 ) dependence on heart rate as: where ↵ HR = 15.14, HR = 1.88, HR = 4.17. ⇠ HR = HR 60 60 . Eq. 2 was fitted for all 243 participants (male and female), and is useful over the range 45 85 bpm.

244
A. E↵ect of COVID-19 on the respiratory rate

245
In this section, we present results from a subset of the Fitbit COVID-19 data survey.

246
Let µ and be the mean and standard deviation of the respiratory rate for a specific user, 247 estimated several days prior to the onset of illness. The Z score on a given day D n may be 248 defined as where R(D n ) is the respiratory rate for a specific user on day D n . For symptomatic indi- . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity.

(which was not certified by peer review)
The copyright holder for this preprint this version posted May 18, 2021. ; https://doi.org/10.1101/2021.05.15.21257200 doi: medRxiv preprint e↵ect of fever which is known to increase the respiratory rate [35]. The red data points show 267 the probability for N ⇤ = 1 for symptomatic individuals who presented with a fever, while 268 the black data points show the same probability for individuals who did not list fever as a 269 symptom. Plot (d) considers the respiratory rate measured for asymptomatic individuals.

270
The plot shows the probability for N ⇤ = 1, as a function of window center. In all cases,

274
In this article, we showed how to compute the respiratory rate by locating the peak of 275 the RSA feature. We computed the power spectral density from the heart rate interbeat 276 interval time series every 5 minutes. These individual spectra were then aggregated over a 277 night, and the respiratory rate was estimated from the averaged power spectral density. We 278 validated our technique with the help of nasal cannula data consisting of 52 measurements 279 obtained from 28 participants with apnea-hypopnea index < 30. The bias (mean of the 280 predicted rate -true rate) was found to be 0.244 min 1 ( 1.67%) while the RMS error 281 was 0.648 min 1 (4.18%). The mean absolute error was 0.460 min 1 , and the mean absolute 282 percentage error was 3%. The absolute value of bias is larger for low values of respiratory 283 rate. For rates lower than 16 min 1 , the bias is 0.41 min 1 , while for rate 16 min 1 , the 284 bias is 0. 285 We then collected respiratory rate data for 10,000 participants, ranging in age from 20 69 286 years, for both male and female participants. Respiratory rates measured in deep sleep (or 287 light sleep when deep sleep data was unavailable) for adults commonly ranges from 11.8 288 min 1 -19.2 min 1 (90% range). For both males and females, respiratory rate values are 289 inversely correlated with age. From ages 20 yr -50 yr, the Pearson r correlation coe cient 290 for female (male) participants was found to be 0.145( 0.104), while for ages > 50 yr, the 291 corresponding values for females (males) was 0.031( 0.043). The coe cient of variation on 292 the other hand, increases with age ( Fig.4(b)). The coe cient of variation is higher in males 293 compared to females, for ages greater than 60, with no di↵erence for age < 60 yr. From age 294 20-24 yr, the coe cient of variation measured over a 14 day period range for female (male) 295 12 . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity.

297
Respiratory rate varies with BMI, reaching a minimum at a BMI of 25 kg/m 2 . It also varies 298 with heart rate, increasing with increase in heart rate measured during non-REM sleep. We 299 note however that BMI and heart rate are not independent of each other [36]. 300 We see an interesting behavior in the way the respiratory rate varies with age for female 301 and male participants (see Fig.4(a)). Female subjects have a higher respiratory rate than 302 males for age < 50 yr, while for age > 50 yr, there is no di↵erence between males and 303 females. Female participants on average, have a higher heart rate than males [37], and we 304 have shown that the respiratory rate is elevated in individuals with a higher heart rate.

305
To determine whether the increased heart rate in females could contribute to the increased 306 respiratory rate, we use Eq. 5 to obtain where HR is the heart rate, H 60 = HR / (60 bpm), and R is the mean respiratory rate for 308 individuals with a heart rate HR. For the age group 20 24 yr, we find that male participants 309 have hH 60 i = 1.0031. For female participants in the same age group, we find hH 60 i = 1.1123,

310
giving us h H 60 i = 0.1092. The correlation between heart rate and respiratory rate implies 311 that the increased heart rate can account for at most an excess of R ⇡ 0.208 min 1 .

312
The true di↵erence in respiratory rates between females and males in this age group is 1.2 313 min 1 (Fig. 4(a)). The increased heart rate in females can thus account for only 17.3% 314 of the di↵erence between the respiratory rates of females and males. As a further test, we 315 considered heart rate bins of 5 bpm, and selected male and female individuals within the 316 same age bin, and the same heart rate bin. With 280 female, and 357 male participants in 317 the heart rate bin 57.5 62.5 bpm, and the age bin 20 24 yr, we find a mean respiratory 318 rate of 16.5 min 1 for females, and 15.6 min 1 for males, with an e↵ect size of 0.38, and a 319 p value of 1.54 ⇥ 10 6 . Similar computations can be made for other heart rate bins and 320 age groups. While the e↵ect size is slightly decreased compared to the case where the heart 321 rate is unrestricted, the increased nocturnal heart rate in females cannot solely explain 322 the increase in respiratory rate. A striking feature seen in Fig.4(a) is the rapid decrease 323 in the mean respiratory rate in female participants around the age ⇡ 50 yr. This leads 324 us to hypothesize that sex hormones are responsible for the di↵erence in respiratory rates 325 13 . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity.

(which was not certified by peer review)
The copyright holder for this preprint this version posted May 18, 2021. ;https://doi.org/10.1101https://doi.org/10. /2021 between men and women. It is well known that some sex hormones such as progesterone act 326 as respiratory stimulants [38][39][40]. Since progesterone secretion decreases after menopause 327 [38,40], it is likely that the change in mean respiratory rate seen in females at age ⇡ 50 yr 328 is associated with menopause.

329
Finally, we studied how respiratory rate is a↵ected by COVID-19. We computed res- symptomatic individuals presenting with a fever (Fig. 6(c)), the P (N 1) plot peaks at 353 71.5%, while for symptomatic individuals who do not present with a fever, the plot peaks 354 at 47.3%. For asymptomatic individuals (Fig. 6(d)), the plot for N ⇤ = 1 peaks at 33.3%.

355
This is smaller than for symptomatic individuals (59.3%) and for individuals who present 356 with a fever (71.5%).

357
14 . CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity. (which was not certified by peer review)

26
. CC-BY-NC-ND 4.0 International license It is made available under a is the author/funder, who has granted medRxiv a license to display the preprint in perpetuity. (which was not certified by peer review) The copyright holder for this preprint this version posted May 18, 2021. ;https://doi.org/10.1101https://doi.org/10. /2021