Summarizing data from continuous glucose monitors using the cgmstats command.
Natalie Daya Malek, Dan Wang, Sui Zhang, Michael Fang, Amelia Wallace, Scott Zeger, Elizabeth Selvin
Johns Hopkins Bloomberg School of Public Health (Welch Center for Prevention, Epidemiology, and Clinical Research) and a longtime Stata user. · Biostatisticians at the Johns Hopkins Bloomberg School of Public Health (Welch Center for Prevention, Epidemiology, and Clinical Research) and longtime Stata users.
Abstract
In this article, we present the cgmstats package for the analysis of continuous glucose monitoring (CGM) data. The use of wearable CGMs is growing rapidly. The latest generation of CGM systems do not require fingerstick calibration, are minimally invasive, and are frequently used in research studies. CGM sensors are typically worn for up to 2 weeks and record interstitial glucose measurements every minute to every 15 minutes, depending on the sensor used. CGM systems generate hundreds of measurements per day and thousands of measurements in one person over a single wear. There is a need for tools that allow researchers to efficiently organize and summarize the wealth of data on glucose patterns produced by CGM systems. The cgmstats package generates CGM summary measures for data from a variety of CGM systems and allows the user to flexibly define ranges and generate data visualizations. In this article, we provide an overview of the cgmstats package and examples of its use. The cgmstats package supports rigorous and reproducible analyses of CGM data.
Read the paper
Discussion
Science Skim's AI key points, plus readers' public thoughts
Readers' thoughts
No reader thoughts yet.
Related papers
- International clinical opinion on transparency, standardisation, and calibration alignment in the performance evaluation of systems for continuous glucose monitoringDiabetes Obesity and Metabolism · 2026
- Continuous glucose monitoring (CGM) systems in Poland, Europe, and beyond in 2025: principles, available technologies, and future perspectives.Archives of medical science : AMS · 2026
- Integrating the Glycemia Risk Index Into Clinical Practice and Research: A Consensus ReportJournal of Diabetes Science and Technology · 2026
- Toward standardized continuous glucose monitoring validation: lessons from the Sinocare iCan i3 accuracy study.Frontiers in clinical diabetes and healthcare · 2026
- Continuous glucose monitoring for diabetes prevention in adults with prediabetes: a scoping review.Frontiers in endocrinology · 2026
- Controlled In Vitro Characterization of the Dynamic Response of Continuous Glucose Monitoring Systems: Adaptation of a Programmable Flow Platform and Decomposition of Dynamic ErrorbioRxiv · 2026