Validation of Data Imputation by Ensemble Averaging to Quantify 24-h Behavior Using Heart Rate of Stroke Rehabilitation Inpatients



Recent advances in wearable technology have enabled us to visualize how stroke patients spend time and how they behave during physical activity over a period of 24-h. This capability is expected to provide new insights into rehabilitation research. However, wearable electrocardiograph (ECG) monitoring devices generate noise and artifacts from external factors such as body movements, which causes misdetection of the R wave. To compensate for the loss of heart rate data due to misdetection, the present study focused on ensemble averaging as a method to impute missing data and validated this method of data imputation on 24-h recordings.


First, to investigate the measurement period for data imputation, we continuously measured heart rates of six healthy participants for four days and applied ensemble averaging to the first two, three and all four days of measurement data. Next, we validated the imputation by ensemble averaging with 218 measurement data from 63 stroke inpatients in a rehabilitation ward.


For the healthy participants, the period with data losses decreased from 115 min (8.3% of the 24-h) to 5.5 min (0.4%), 0 min (0%), and 0 min (0%) when ensemble averaging was applied to two, three, and four days of measurement data, respectively. For data of stroke patients acquired in a two-day measurement session, ensemble averaging decreased the period with data losses more than the conventional method that selects data of the day with the least missing data among the measurement days did (0.17 and versus 1.7% of the 24-h). The median and maximum heart rate when ensemble averaging was applied was strongly correlated to the median and maximum heart rate when ensemble averaging was not applied.


The results suggest that ensemble averaging is useful for imputing missing vital data such as heart rate.

This is a preview of subscription content, access via your institution.

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7

Data Availability

The data set used and/or analyzed during the current study are available from the corresponding author on reasonable request.

Code Availability

The code used during the current study is available from the corresponding author upon reasonable request.


  1. 1.

    Willetts, M., Hollowell, S., Aslett, L., Chris, H., & Aiden, D. (2018). Statistical machine learning of sleep and physical activity phenotypes from sensor data in 96,220 UK Biobank participants. Science and Reports, 8, 7961.

    CAS  Article  Google Scholar 

  2. 2.

    Rosenberger, M. E., Buman, M. P., Haskell, W. L., Mcconnell, M. V., & Carstensen, L. (2016). Twenty-four hours of sleep, sedentary behavior, and physical activity with nine wearable devices. Medical & Science in Sports & Exercise, 48(3), 457–465.

    Article  Google Scholar 

  3. 3.

    Nelson, B. W., & Allen, N. B. (2019). Accuracy of consumer wearable heart rate measurement during an ecologically valid 24-hour period: Intraindividual validation study. JMIR mHealth and uHealth, 7(3), e10828.

    Article  Google Scholar 

  4. 4.

    Jung, H., Kwon, D., Lee, S., Kim, Y., & Ahn, J. W. (2019). Carbon nanofiber-based wearable patches for bio-potential monitoring. Journal of Medical and Biological Engineering, 39, 892–900.

    Article  Google Scholar 

  5. 5.

    Shen, C., Huang, T., Hsu, P., Ko, Y., Chen, F., Wang, W., et al. (2017). Respiratory rate estimation by using ECG, impedance, and motion sensing in smart clothing. Journal of Medical and Biological Engineering, 37, 826–842.

    Article  PubMed  PubMed Central  Google Scholar 

  6. 6.

    Lin, C., Liou, Y., Zhou, Z., & Wu, S. (2019). Intelligent exercise guidance system based on smart clothing. Journal of Medical and Biological Engineering, 39, 702–712.

    Article  Google Scholar 

  7. 7.

    Paul, L., Brewster, S., Wyke, S., Gill, J. M. R., Alexander, G., Dybus, A., et al. (2015). Physical activity profiles and sedentary behaviour in people following stroke: A cross-sectional study. Disability and Rehabilitation, 20, 1–6.

    Article  Google Scholar 

  8. 8.

    Simpson, D. B., Breslin, M., Cumming, T., de Zoete, S. A., Gall, S. L., Schmidt, M., et al. (2020). Sedentary time and activity behaviors after stroke rehabilitation: Changes in the first 3 months home. Topics in Stroke Rehabilitation, 28, 42–51.

    Article  PubMed  Google Scholar 

  9. 9.

    Barrett, M., Snow, J. C., Kirkland, M. C., Kelly, L. P., Gehue, M., & Downer, M. B. (2018). Excessive sedentary time during in-patient stroke rehabilitation. Topics in Stroke Rehabilitation, 25, 366–374.

    Article  PubMed  Google Scholar 

  10. 10.

    Mahendran, N., Kuys, S. S., & Brauer, S. G. (2016). Recovery of ambulation activity across the first six months post-stroke. Gait & Posture, 49, 271–276.

    Article  Google Scholar 

  11. 11.

    Langhammer, B., & Lindmark, B. (2012). Functional exercise and physical fitness post stroke: the importance of exercise maintenance for motor control and physical fitness after stroke. Stroke Research and Treatment, 2012, 864835.

    Article  PubMed  PubMed Central  Google Scholar 

  12. 12.

    Patel, S., Park, H., Bonato, P., Chan, L., & Rodgers, M. (2012). A review of wearable sensors and systems with application in rehabilitation. Journal of NeuroEngineering and Rehabilitation, 9, 21.

    Article  PubMed  PubMed Central  Google Scholar 

  13. 13.

    Hutcheon, J. A., Chiolero, A., & Hanley, J. A. (2010). Random measurement error and regression dilution bias. BMJ, 340, c2289.

    Article  PubMed  Google Scholar 

  14. 14.

    Eguchi, K., Aoki, R., Shimauchi, S., Yoshida, K., & Yamada, T. (2018). R-R interval outlier processing for heart rate variability analysis using wearable ECG devices. Advanced Biomedical Engineering, 7, 28–38.

    Article  Google Scholar 

  15. 15.

    Friesen, G. M., Jannett, T. C., Jadallah, M. A., Yates, S. L., Quint, S. R., & Nagle, H. T. (1990). A comparison of noise sensitivity of nine QRS detection algorithms. IEEE Transactions on Biomedical Engineering, 37(1), 85–98.

    CAS  Article  PubMed  Google Scholar 

  16. 16.

    Muzi, M., Ebert, T. J., Tristani, F. E., Jeutter, D. C., Barney, J. A., & Smith, J. J. (1985). Determination of cardiac output using ensemble-averaged impedance cardiograms. Journal of Applied Physiology, 58(1), 200–205.

    CAS  Article  PubMed  Google Scholar 

  17. 17.

    Hurwitz, B.E., Shyu, L.Y., Reddy, S.P., Schneiderman, N., & Nagel, J.H. (1990). Coherent ensemble averaging techniques for impedance cardiography. In Proceedings of Third Annual IEEE Symposium on Computer-Based Medical Systems, 228–235.

  18. 18.

    He, D. D., Winokur, E. S., & Sodini, C. G. (2015). An ear-worn vital signs monitor. IEEE Transactions on Biomedical Engineering, 62(11), 2547–2552.

    Article  PubMed  Google Scholar 

  19. 19.

    Ogasawara, T., Matsunaga, K., Ito, H., & Mukaino, M. (2018). Application for rehabilitation medicine using wearable textile “hitoe”. NTT Technical Review, 16(9), 6–12.

  20. 20.

    Matsunaga, K., Ogasawara, T., Kodate, J., Mukaino, M., & Saitoh, E. (2019). On-site evaluation of rehabilitation patients monitoring system using distributed wireless gateways. Proceedings of International Conference of the IEEE Engineering in Medicine and Biology Society, 2019, 3195–3198.

    Article  Google Scholar 

  21. 21.

    Tsukada, S., Kasai, N., Kawano, R., Takagahara, K., Fujii, K., & Sumitomo, K. (2014). Electrocardiogram monitoring simply by wearing a shirt––for medical, healthcare, sports, and entertainment. NTT Technical Review, 12(4), 1–6.

  22. 22.

    Takagahara, K., Ono, K., Oda, K., & Teshigawara, T. (2014). ‘hitoe’ -a wearable sensor developed through cross-industrial collaboration. NTT Technical Review, 12(9), 1–5.

  23. 23.

    Tsukada, Y. T., Tokita, M., Murata, H., Hirasawa, Y., Yodogawa, K., Iwasaki, Y. K., et al. (2019). Validation of wearable textile electrodes for ECG monitoring. Heart and Vessels, 34, 1203–1211.

    Article  Google Scholar 

  24. 24.

    Mathie, M.J., Basilakis, J., & Celler, B.G. (2001). A system for monitoring posture and physical activity using accelerometers. In Proceedings of International Conference of the IEEE Engineering in Medicine and Biology Society, 3654–3657.

  25. 25.

    Docomo developer support [Internet]. 2015 [cited 2017 Dec 5]. Available from:

  26. 26.

    Nathoo, C., Buren, S., El-Haddad, R., Feldman, K., Schroeder, E., Brooks, D., et al. (2018). Aerobic training in canadian stroke rehabilitation programs. Journal of Neurologic Physical Therapy, 42(4), 248–255.

    Article  PubMed  Google Scholar 

  27. 27.

    Colberg, S. R., Swain, D. P., & Vinik, A. I. (2003). Use of heart rate reserve and rating of perceived exertion to prescribe exercise intensity in diabetic autonomic neuropathy. Diabetes Care, 26, 986–990.

    Article  PubMed  Google Scholar 

  28. 28.

    Swain, D. P. (2000). Energy cost calculations for exercise prescription: An update. Sports Medicine, 30, 17–22.

    CAS  Article  PubMed  Google Scholar 

  29. 29.

    Karvonen, M. J., Kentala, E., & Mustala, O. (1957). The effects of training on heart rate; a longitudinal study. Annales Medicinae Experimentalis et Biologiae Fenniae, 35, 307–315.

    CAS  PubMed  Google Scholar 

  30. 30.

    Matsuura, N., Kuwabara, K.. Takagahara, K., Kawano, R., & Koizumi, H. (2017). Heartbeat detection method and heartbeat detection device. United States patent US, 20170258351A1. 2017 Sep 14

  31. 31.

    Elgendi, M., Eskofier, B., Dokos, S., & Abbott, D. (2014). Revisiting QRS detection methodologies for portable, wearable, battery-operated, and wireless ECG systems. PLoS ONE, 9(1), e84018.

    CAS  Article  PubMed  PubMed Central  Google Scholar 

  32. 32.

    Gellish, R. L., Goslin, B. R., Olson, R. E., McDonald, A., Russi, G. D., & Moudgil, V. K. (2007). Longitudinal modeling of the relationship between age and maximal heart rate. Medicine and Science in Sports and Exercise, 39(5), 822–829.

    Article  PubMed  Google Scholar 

  33. 33.

    Matsuura, H., Mukaino, M., Otaka, Y., Kagaya, H., Aoshima, Y., Suzuki, T., et al. (2019). Validity of simplified, calibration-less exercise intensity measurement using resting heart rate during sleep: A method-comparison study with respiratory gas analysis. BMC Sports Science Medicine and Rehabilitation, 11, 27.

    Article  Google Scholar 

  34. 34.

    Pollock, M. L., Gaesser, G. A., Butcher, J. D., Després, J.-P., Dishman, R. K., Franklin, B. A., & Garber, C. E. (1998). The recommended quantity and quality of exercise for developing and maintaining cardiorespiratory and muscular fitness, and flexibility in healthy adults. Medicine and Science in Sports and Exercise, 30, 975–991.

    Article  Google Scholar 

  35. 35.

    Kwakkel, G., van Peppen, R., Wagenaar, R. C., Wood Dauphinee, S., Richards, C., Ashburn, A., et al. (2004). Effects of augmented exercise therapy time after stroke: A meta-analysis. Stroke, 35(11), 2529–2539.

    Article  PubMed  Google Scholar 

Download references


The authors thank Mr. Kenta Maruyama and Mr. Setsura Kato at NTT Basic Research Laboratories for their technical assistance in the data analysis, Mr. Junichi Kodate and Ms. Rieko Sato at NTT Device Innovation Center for their help in the system’s development, and the nurses and therapists at Fujita Health University Hospital for their support in the experiments.


The authors received no specific funding for this work.

Author information




Conceptualization: Takayuki Ogasawara, Masahiko Mukaino. Methodology: Masahiko Mukaino, Yohei Otaka, Eiichi Saitoh. Formal analysis and investigation: Takayuki Ogasawara. Writing—original draft preparation: Takayuki Ogasawara, Masahiko Mukaino. Writing—review and editing: Yohei Otaka, Masumi Yamaguchi, Hiroshi Nakashima, Shingo Tsukada. Funding acquisition: Hiroyoshi Togo, Hiroshi Nakashima, Yohei Otaka; Resources: Hirotaka Masuura, Yasushi Aoshima, Takuya Suzuki. Supervision: Yohei Otaka, Hiroyoshi Togo, Shingo Tsukada, Eiichi Saitoh.

Corresponding author

Correspondence to Takayuki Ogasawara.

Ethics declarations

Conflict of Interest

The research team was leased wearable clothing from Toray Industries and hardware devices from NTT Corporation, which are manufacturers of measurement tools. Takayuki Ogasawara, Hiroyoshi Togo, Hiroshi Nakashima, Masumi Yamaguchi and Shingo Tsukada are employees of NTT Corporation. The authors declare no other conflicts of interest associated with this manuscript.

Ethical Approval

The study protocol was approved by the Medical Ethics Committee of Fujita Health University (HM17-220).

Consent to Participate

All participants provided written informed consent before participation.

Consent for publication

All participants provided written informed consent before participation.

Rights and permissions

Reprints and Permissions

About this article

Verify currency and authenticity via CrossMark

Cite this article

Ogasawara, T., Mukaino, M., Otaka, Y. et al. Validation of Data Imputation by Ensemble Averaging to Quantify 24-h Behavior Using Heart Rate of Stroke Rehabilitation Inpatients. J. Med. Biol. Eng. 41, 322–330 (2021).

Download citation


  • Ensemble averaging
  • Wearable
  • Rehabilitation
  • Stroke
  • Inpatient