Abstract
Aims
Patterns in physical behaviour may be associated with an increased risk of ventricular arrhythmia. We examined associations between temporal dynamics in physical behaviour measured through wearable technology and the risk of ventricular arrhythmia
Methods and results
The multicentre, prospective SAFEHEART study recruited 303 patients with an implantable cardioverter-defibrillator (ICD) from May 2021 to September 2022. Continuous physical behaviour data were collected over 365 consecutive days and nights using wearable accelerometers. We characterized each 28-day behavioural time series using statistical summary indices and deep representations learned by neural networks. Logistic regression analyses were used to estimate the associations between physical behaviour and the subsequent risk of ventricular arrhythmia as detected by ICD and treated appropriately. Predictive performance was assessed using k-fold cross-validation and quantified by the area under the receiver operating characteristic curve (AUROC). From the SAFEHEART cohort, 277 patients and 56 ventricular arrhythmia were analysed, contributing to a total of 64 995 days of behavioural data. Reduced numbers of daily physical activity bouts and low day-to-day variation in sleep characteristics were associated with an increased risk of an arrhythmic event. Deep representations improved the predictive performance, with an AUROC of 0.74 ± 0.05, compared with statistical summary indices with an AUROC 0.67 ± 0.14 (P = 0.05 for comparison).
Conclusion
Our findings suggest that behavioural patterns captured through wearable technology are independently associated with ventricular arrhythmia, particularly when these are characterised by deep representations.
Keywords: Wearable activity tracker, Artificial intelligence, Ventricular arrhythmia, Implantable cardioverter-defibrillator
Graphical Abstract
Graphical Abstract.
Introduction
There is a growing interest in physical behaviour as a risk predictor for ventricular arrhythmia, a major cause of sudden cardiac death globally.1,2 Prior studies have demonstrated associations between varying levels of physical activity at baseline and the risk of incident ventricular arrhythmia.3,4 However, the mechanisms influencing the risk of ventricular arrhythmia are dynamic rather than static, necessitating longitudinal behavioural monitoring to detect prognostically relevant changes. A decline in activity prior to ventricular arrhythmia has been previously described, occurring anywhere from 2 months to 14 days before the event.5–8 Given the complexity of 24-h rest and activity behaviours, which extend well beyond physical activity alone, there is a growing interest in wearable technology for the passive monitoring of overall physical behaviour.3,4 Wearable accelerometers facilitate the continuous measurement of a comprehensive array of parameters, including sleep patterns, daily activities, posture changes, rest–activity patterns, and sedentary behaviours. Yet, the potential of these behavioural metrics, measured over an extended period, to serve as early warning signs for ventricular arrhythmias, is unknown. Using physical behaviour data collected over a period of 12 months from wearable devices, we aimed to explore associations between day-to-day physical behaviour measurements and the risk of ventricular arrhythmia. Second, we examined the added value of deep representation learned by a neural network, in comparison with statistical summary indices, for predicting ventricular arrhythmia onset.
Methods
Study design
The SAFEHEART study was a multicentre, prospective observational study, conducted at Amsterdam University Medical Center in the Netherlands and Copenhagen University Hospital—Rigshospitalet in Copenhagen, Denmark.9 All participants were enrolled between May 2021 and September 2022. Patient inclusion was conducted via telephone-based procedures, with the first day of the study defined as the day when the wearable device was delivered to the patient (Figure 1A). Patients were eligible for this sub-study if they met the minimum required number of days of behavioural data, as described below. We adhered to the Strengthening the Reporting of Observational Studies in Epidemiology (STROBE) reporting guidelines for observational studies.10
Figure 1.
Study workflow. (A) Patients were recruited from two European sites and monitored for 12 months with a wearable accelerometer, with prospective collection of arrhythmic endpoints. (B) Behavioural time series were divided into discrete 28-day segments, characterized through statistical summary indices and deep representations. (C) Logistic regression models were used to explore the associations between the behavioural characteristics and the endpoint. K-fold cross-validation was employed to assess the predictive performance of both models. Deep representations were explained through GradCAM and factor traversal.
Participants
Participants were eligible to enrol in the SAFEHEART study if they met the following criteria: (i) had received an implantable cardioverter-defibrillator (ICD), with or without cardiac resynchronization therapy (CRT), within the 5 years preceding enrolment; (ii) had undergone appropriate or inappropriate ICD therapy [such as high-voltage shock therapy or anti-tachycardia pacing (ATP)], or showed evidence of ventricular arrhythmias within 8 years before enrolment; (iii) were engaged in a remote ICD monitoring programme; and (iv) were at least 18 years old. The study protocol, detailing the full list of inclusion and exclusion criteria, has been published previously.9
Ethics
Ethical approval for the study protocol was obtained from the medical ethics board at both study sites on 18 December 2020 (METC 2020-248) and 19 April 2021, respectively. All participants provided written informed consent prior to their enrolment. The study was conducted in accordance with the Helsinki declaration. The study was registered at the National Trial Registration in the Netherlands (Trial NL9218; https://www.onderzoekmetmensen.nl/en).
Data collection and processing
During the study, participants wore a tri-axial accelerometer (Activinsights Ltd, Cambridgeshire, UK) on their wrist continuously for 365 days. Upon enrolment, participants received the wearable devices, which were dispatched from Activinsights directly to the participant’s home address. Two accelerometer devices were used in the study: the GENEActiv and Activinsights Band. The GENEActiv device was periodically replaced (every 2–4 weeks) for data download during the first half of the study, while the Activinsights Band automatically stored and uploaded data through an application on a patient-owned smart device. Patients were also able to use either device exclusively throughout the entire study duration (e.g. patients without a smart device to connect to). This means that a few patients only used the Activinsights Band (n = 2), or transitioned onto it early (n = 3), while five patients moved back to the GENEActiv after starting on the Activinsights Band. Continuous raw accelerometer data was recorded at 50 or 20 Hz from the GENEActiv device and variable-length behavioural bouts from the Activinsights Band. These data were subsequently converted into daily summaries using an open-source R package, generating behavioural time series data for each patient over 365 days.11 The daily measures obtained from both wearables were transformed to ensure uniformity of the data for analysis. This involved Box Cox transformation and normalisation, resulting in z-scores for each metric. In total, 13 behavioural metrics were chosen based on their ability to consistently explain the most variance within and between patients (see Supplementary material online, Table S1). Patients were eligible for this study if they had at least 28 days of wearable data. Missing data were imputed through seasonally decomposed imputation methods (R package imputeTS; Supplementary material online, Figure S1, shows an example of the imputation result).12 Behavioural time series were split into contiguous periods of 28 days giving each patient 13 unique periods (Figure 1B; Supplementary material online, Figure S2). Monitoring periods without any wear time were removed from the analysis. In individuals who met the endpoint, the 28-day period prior to the event was extracted, with a minimum of 28 days between individual events.
Characterization of physical behaviour
We characterized individual 28-day intervals of behavioural measurements using two different approaches: statistical summary indices and deep representations (Figure 1B). First, we calculated the slope of the linear regression line to indicate the trend, the variance to indicate the variability, and the median value to indicate the central tendency for each 28-day interval. Second, a β-variational autoencoder (VAE), a type of neural network designed to generate a compressed representation of input data by encoding and decoding, was used to learn the deep representations from the behavioural time series.13,14 Unlike traditional autoencoders, the β-VAE introduces a probabilistic element, allowing the model to learn a probabilistic mapping between the input data and a lower-dimensional latent space. The β-VAE learns by optimizing the evidence lower bound (ELBO), which consists of the reconstruction error and the Kullback–Leibler (KL) divergence. The parameter β balances these two aspects, allowing for flexible control over how much the model prioritizes accurate reconstruction vs. structured latent space.14 Residual blocks were used to preserve information through skip connections, allowing gradients to flow more smoothly during training and mitigating the vanishing gradient problem. Both the encoder and decoder consisted of several convolutional layers followed by batch normalization and an exponential linear unit (ELU) activation function. The decoder used transpose convolutions to transform the sampled set of features from the latent distribution back into the original data. The model was trained with a learning rate of 0.0001 using the Adam optimiser, a batch size of 128, and a total of 500 epochs, with early stopping and a learning rate scheduler to optimise the training process.14 Supplementary material online, Figure S3 and S4, provide a schematic representation of the VAE and a reconstructed behavioural time series, respectively. The lower-dimensional deep representations learned by the VAE capture the important features and patterns in the discrete 28-day intervals of behavioural data. These latent variables are 1D feature vectors that can be used for downstream tasks, such as regression analysis. Since these deep representations are abstract values and not directly interpretable, we used two methods to gain insights into their meaning. First, we generated gradient-based attention maps to visualize the important trajectories within the behavioural time series.15 Second, we applied factor traversal to assess the effect of changing an individual deep representation on the decoded output.16 The VAE models were developed using PyTorch (version 2.0.5) in Python (version 3.6.7).
Outcome
The outcome of interest was defined as any ventricular arrhythmia treated by the ICD through an appropriate shock and/or ATP. For patients receiving shocks or ATP during the trial, intracardiac electrograms (EGMs) at the time of the device therapy were obtained. Therapies were adjudicated by a committee of electrophysiologists as appropriate ICD therapy for ventricular fibrillation or sustained ventricular tachycardia, or inappropriate ICD therapy (e.g. ICD therapy for any other rhythm, device errors). To be included in this study, outcomes had to occur at least 28 days following enrolment and the use of the wearable device, and they could not be preceded by another outcome in the last 28 days.
Statistical analysis
Continuous variables were presented with their median, mean, interquartile range (IQR), and standard deviation. Categorical sociodemographic and clinical variables were expressed as frequencies (percentages) and compared using Fisher’s exact test when appropriate; otherwise, the χ2 test was used. Associations between physical behaviours and the risk of the outcome were evaluated using logistic regression analyses. Separate models were constructed for discrete 28-day intervals characterized by statistical summary indices and the deep representations. Multicollinearity was assessed using the variance inflation factor (VIF), with values exceeding the threshold of >5 considered indicative of multicollinearity and thus being removed. Models were adjusted for clinical covariates, including age, sex, indication for ICD implantation (primary vs. secondary prevention), CRT, presence of heart failure with reduced ejection fraction, atrial fibrillation, ischaemic heart disease, diabetes mellitus, and body mass index. To evaluate the predictive performance of physical behaviour statistical summary indices and deep representations, a stratified k-fold cross-validation (5-fold) procedure was employed, ensuring distinct patients were exclusively allocated to either training or validation folds. Variable selection was performed within each fold using backward selection of variables based on the Akaike information criterion using data from the training fold. Model performance was visualized using receiver operating characteristic (ROC) curves, and assessed based on the area under the ROC curve (AUROC). Model AUROCs were compared using DeLong’s test for two unpaired ROC curves. Overall goodness-of-fit was evaluated with the Brier score, and calibration was assessed using plots of observed vs. predicted risk. Sensitivity analysis was conducted for models trained exclusively on statistical summary indices, or deep representations, excluding clinical variables.
Results
A total of 303 patients [mean age 62.9 ± 10.9 years, 246 (81.2%) male] were enrolled in the study, of which 26 patients did not have sufficient behavioural data for the present analysis, while the remaining 277 patients had 65 115 days of behavioural data meeting the eligibility criteria for analysis. Figure 2 displays the selection of patients and outcomes. Fifteen patients were excluded because they did not have any valid day of wear time; 11 patients did not meet the minimum of 28 days of wearable data. Patients with eligible data had a median of 253 days (IQR 180–307) with behavioural measurements. The baseline characteristics of the final patient cohort are shown in Table 1.
Figure 2.
Flowchart of patient recruitment and selection of arrhythmia episodes.
Table 1.
Baseline characteristics
| Patient cohort (n = 277) | No endpoint (n = 226) | Appropriate therapy (n = 51) | |
|---|---|---|---|
| Age, years (SD) | 63.2 (10.5) | 62.8 (10.5) | 64.8 (10.5) |
| Male, n (%) | 225 (81.2) | 179 (79.2) | 46 (90.2) |
| Secondary prevention ICD, n (%) | 191 (69.0) | 156 (69.0) | 35 (68.6) |
| Body mass index, kg/m2 (SD) | 28.1 (6.0) | 28.2 (6.3) | 27.7 (4.8) |
| Smoking, n (%) | |||
| Never | 99 (35.7) | 78 (34.5) | 21 (41.2) |
| Previous | 105 (37.9) | 86 (38.1) | 19 (37.3) |
| Active | 41 (14.8) | 36 (15.9) | 5 (9.8) |
| Cardiovascular history, n (%) | |||
| Ischaemic heart disease | 136 (49.1) | 113 (50.0) | 23 (45.1) |
| Myocardial infarction | 104 (37.5) | 83 (36.7) | 21 (41.2) |
| PCI | 92 (33.2) | 74 (32.7) | 18 (35.3) |
| CABG | 52 (18.8) | 44 (19.5) | 8 (15.7) |
| Heart failure (HFrEF) | 149 (53.8) | 114 (50.4) | 35 (68.6) |
| Diabetes mellitus | 45 (16.2) | 38 (16.8) | 7 (13.7) |
| Hypertension | 140 (50.5) | 117 (51.8) | 23 (45.1) |
| Cerebral vascular event | 29 (10.5) | 22 (9.7) | 7 (13.7) |
| Atrial fibrillation | 95 (34.3) | 78 (34.5) | 17 (33.3) |
| Medication, n (%) | |||
| ACE inhibitor | 112 (40.4) | 86 (38.1) | 26 (51.0) |
| Angiotensin receptor blocker | 68 (24.5) | 59 (26.1) | 9 (17.6) |
| Loop diuretics | 92 (33.2) | 76 (33.6) | 16 (31.4) |
| AAD Class I | 8 (2.9) | 8 (3.5) | 0 (0) |
| AAD Class III | 47 (17.0) | 35 (15.5) | 12 (23.5) |
| β-blocker | 224 (80.9) | 176 (77.9) | 48 (94.1) |
| Calcium channel blockers | 43 (15.5) | 40 (17.7) | 3 (5.9) |
| Lipid-lowering drugs | 178 (64.3) | 147 (65.0) | 31 (60.8) |
| Implanted device, (%) | |||
| Single-chamber | 162 (58.5) | 133 (58.8) | 29 (56.9) |
| Dual-chamber | 61 (22.0) | 47 (20.8) | 14 (27.5) |
| CRT-D | 52 (18.8) | 45 (19.9) | 7 (13.7) |
ACE, angiotensin-converting enzyme; CABG, coronary artery bypass grafting; CRT, cardiac resynchronization therapy; HFrEF, heart failure with reduced ejection fraction; PCI, percutaneous coronary intervention; SD, standard deviation.
Discrete 28-day intervals were processed to create a long format data set where each row represents an interval. During the study, there were a total of 90 episodes of appropriate ICD therapy in 53 patients. This comprised ATP only (79 episodes), shock only (6 episodes), or ATP and shock (5 episodes). Of these, 56 episodes in 51 patients were eligible for the current analysis, whereas the remaining 34 episodes in 2 patients were excluded because of very early occurrence or multiple episodes within 28-day intervals (Figure 2). Four patients died during follow-up, two of which did not meet the endpoint and were kept in the data set. The final data set consisted of 51 patients with 56 28-day intervals followed by the outcome of appropriate ICD therapy and 226 patients with 2994 intervals without subsequent outcome, of which 590 intervals were excluded due to non-wear.
Physical behaviour characterized by statistical summary indices
Table 2 presents the physical behaviour characteristics across the patient cohort. The daily median time spent inactive was 13.7 h (IQR 13.2–14.6). The duration of moderate-to-vigorous activity was 3.1 h (IQR 2.6–3.8), and patients engaged in a median of 260 active events (IQR 247285). In univariable regression, a low daily number of physical activity events was associated with a higher risk of the endpoint [odds ratio (OR) = 0.73, 95% confidence interval (CI) 0.58–0.94, P = 0.014] (Table 3; Supplementary material online, Figure S5). Furthermore, lower day-to-day variation in sleep characteristics was associated with an increased risk of the endpoint, specifically, lower variance in sleep duration (hours) (OR = 0.16, 95% CI 0.05–0.44, P < 0.001), number of waking after sleep onset episodes (count) (OR = 0.28, 95% CI 0.12–0.62, P = 0.003), and sleep efficiency (%) (OR = 0.36, 95% CI 0.15–0.80, P = 0.018). In the model adjusted for clinical covariates, these variables retained their associations with the endpoint. Notably, median active intensity exhibited a positive association with the outcome in the adjusted model (OR = 1.29, 95% CI 1.00–1.65, P = 0.047) only.
Table 2.
Baseline physical behaviour characteristics
| Intervals without event (n = 2404) | Intervals prior to appropriate therapy (n = 51) | |
|---|---|---|
| Activity behaviour, median (IQR) | ||
| Inactive duration, hours | 13.7 (13.2–14.6) | 13.7 (13.1–14.8) |
| Active events, count | 259.5 (247.2–284.7) | 260.8 (249.4–284.9) |
| M6 intensity, mg | 0.29 (0.27–0.33) | 0.3 (0.3–0.3) |
| Active intensity, mg | 0.10 (0.10–0.11) | 0.10 (0.1–0.1) |
| Activity volume, mg/day | 2790.7 (2490.1–3294.4) | 2906.3 (2577.4–3277.4) |
| Cadence 95th percentile, steps/min | 96.1 (91.3–103.2) | 101.6 (94.1–105.5) |
| Moderate-to-vigorous physical activity, hours | 3.1 (2.6–3.8) | 3.4 (2.7–4.0) |
| Sleep behaviour, median (IQR) | ||
| Sleep interval duration, hours | 10.7 (10.1–11.8) | 10.5 (10.1–11.9) |
| Total sleep duration, hours | 6.5 (6.1–7.1) | 6.4 (6.2–6.8) |
| Sleep efficiency, % | 67.9 (65.7–70.5) | 67.9 (65.5–70.5) |
| Mid-sleep time, hours | 11.8 (11.5–12.4) | 12.0 (11.7–12.4) |
| Wake up after sleep onset, count | 30.1 (27.6–33.4) | 28.9 (27.2–32.6) |
| Sleep events number, count | 129.1 (120.4–138.3) | 124.8 (118.1–141.4) |
IQR, interquartile range.
Table 3.
Significant associations between the statistical summary indices and the endpoint in unadjusted and adjusted logistic regression analyses
| Unadjusted model | Adjusted modela | |||
|---|---|---|---|---|
| OR (95% CI) | P-value | OR (95% CI) | P-value | |
| Active events count (median) | 0.73 (0.58–0.94) | 0.011 | 0.69 (0.53–0.89) | 0.004 |
| Active intensity (median) | — | — | 1.29 (1.00–1.65) | 0.047 |
| WASO count (median) | 0.69 (0.51–0.93) | 0.017 | 0.71 (0.52–0.97) | 0.031 |
| Sleep interval duration (variance) | 0.47 (0.24–0.84) | 0.021 | 0.49 (0.25–0.86) | 0.025 |
| Total sleep duration (variance) | 0.16 (0.05–0.44) | <0.001 | 0.16 (0.05–0.44) | 0.001 |
| Sleep efficiency (variance) | 0.36 (0.15–0.80) | 0.018 | 0.34 (0.14–0.77) | 0.015 |
| WASO count (variance) | 0.28 (0.12–0.62) | 0.003 | 0.29 (0.12–0.64) | 0.005 |
| Sleep events number (variance) | 0.37 (0.13–0.91) | 0.047 | 0.35 (0.12–0.88) | 0.041 |
OR, odds ratio; CI, confidence interval; WASO, waking after sleep onset.
aThe adjusted model was controlled for covariates including age, sex, secondary prevention status, diabetes mellitus, atrial fibrillation, heart failure with reduced ejection fraction, cardiac resynchronization therapy, ischaemic heart disease, and body mass index.
Physical behaviour characterized by deep representations
Discrete 28-day behavioural time series were condensed into 16 deep representations. Unadjusted regression analysis identified four of these to be significantly associated with the endpoint (see Supplementary material online, Figure S6). After adjustment for clinical covariates, two deep representations (2nd deep representation, OR 2.03, 95% CI 1.00–4.04, P = 0.048; 11th deep representation OR 0.43, 95% CI 0.23–0.85, P = 0.013) were associated with the endpoint. Figure 3A and B presents sample visualizations of gradient-based activation maps that highlight critical regions within the behavioural time series for these deep representations. Notably, the heatmaps highlighted a distinct region closer to the event as the most salient, in particular the active events, intensity, and volume. This suggests that activity patterns closer to the event may be more predictive. In the control scenario, the heatmap showed large areas of interest, specifically for sleep characteristics. Figure 3C and D illustrates the behavioural patterns represented by the 2nd and 11th deep representation, derived using factor traversal. The 2nd deep representation was associated with an increased risk of the outcome through a low number of active events, a decline in wake after sleep onset count, and a later mid-sleep time. In addition, the 11th deep representation represented a lower active intensity, shorter inactive duration, and more sleep events.
Figure 3.
Deep representations explained through GradCAM and factor traversal. (A, B) GradCAM visualization highlights the regions of interest in the behavioural trajectories for the set of prognostic behavioural representations (those with significant associations to the endpoint in the unadjusted model). (C, D) Factor traversal visualizes the effect of a change in an individual deep representation to high-risk and low-risk values on the decoded output from the autoencoder.
Predictive performance of wearable behaviour data models
The model trained on the statistical summary indices and clinical variables achieved an AUROC of 0.67 ± 0.14 and a Brier score of 0.03 ± 0.12. Similarly, the AUROC of the model using deep representations instead was 0.74 ± 0.05, with a Brier score of 0.02 ± 0.01 (DeLong’s P = 0.055 for comparison). Figure 4A displays the ROC curves. The calibration curves for the statistical summary indices and deep representations are shown in Figure 4B, indicating good calibration for the latter, with close alignment between predicted and observed probabilities. In sensitivity analysis, the AUROC of the statistical summary indices alone was 0.62 ± 0.10, while that of the deep representations was 0.70 ± 0.17 (DeLong’s P = 0.019 for comparison) (see Supplementary material online, Figure S7).
Figure 4.
Receiver operating characteristic curves and calibration plots of predicted vs. observed probabilities of the endpoint. (A) Receiver operating characteristic curve (averaged over 5-fold cross-validation) depicting the performance of multivariable logistic regression models, trained on deep representations (red) and statistical summary indices (blue) extracted from discrete 28-day monitoring intervals. Shaded areas represent one standard deviation. (B) Calibration of the models visualised using the predicted vs. observed risk of the endpoint. Regression lines are drawn, shaded areas represent the 95% confidence interval.
Discussion
This study is the first to prospectively monitor a large cohort of patients at risk of ventricular arrhythmia over a 12-month period using a wearable accelerometer. We analysed 65 115 days of behavioural data, characterizing discrete 28-day monitoring intervals through statistical summary indices (slope, variance, and median) and deep representations learned by a neural network. Our results revealed two important findings. First, we observed that behavioural measurements obtained using a wearable device improved the accuracy of short-term ventricular arrhythmia prediction. In particular, fewer physical activity bouts per day and reduced day-to-day variation in sleep characteristics were associated with an increased risk of ventricular arrhythmia. Second, the predictive capacity of the deep representations (AUROC 0.74 ± 0.05) was higher compared with statistical summary indices (AUROC 0.67 ± 0.14), which suggests that the important intricate patterns within the physical behaviour trends are captured by the first. Altogether, these findings illustrate the potential of monitoring with wearables to predict imminent ventricular arrhythmia that may warrant preventive measures.
A large number of studies have analysed data from the open-source UK Biobank, reporting associations between physical activity measured over 7 days and the risk of incident atrial and ventricular arrhythmia, hospitalization, heart failure, and death.3,4,17,18 Despite the known protective effect of habitual physical activity on cardiovascular health, these studies have used baseline measurements that may not reflect the dynamic change in activity and sleep characteristics preceding an arrhythmic event.2,19 For instance, a decline in accelerometer-derived activity may reflect progression of heart failure,20 atrial arrhythmia onset,21 and a decline in functional capacity,22 all of which increase the risk of ventricular arrhythmia. Our findings support the notion that patterns in activity and sleep characteristics may be a surrogate for disease progression, such as worsening of myocardial dysfunction, haemodynamic alterations, and supraventricular arrhythmia onset.22,23 Previous studies have demonstrated that these temporal changes in activity improve the prediction accuracy for future arrhythmic events.7,8 Moreover, in line with earlier findings, we observed an association between fewer physical activity bouts and ventricular arrhythmia risk.5,6 However, the majority of these earlier studies has evaluated daily active time obtained from accelerometers embedded in the ICD, although this simple metric only provides a partial reflection of overall physical behaviour. In addition, device-embedded accelerometers have used different threshold to distinguish between periods of activity and inactivity. Conversely, research-grade wearable accelerometers produce raw output that can be converted into specific metrics such as the performance during the most active period of the day, measures of variability and rest–activity patterns. By using this more comprehensive array of behavioural metrics, we aimed to uncover more prognostic, non-invasive digital biomarkers for arrhythmic risk. As such, besides the importance of reduced activity, our findings also revealed that reduced day-to-day variation in sleep behaviour was associated with an increased risk of ventricular arrhythmia. This was in line with the findings from a smaller study that enrolled 27 ICD carriers, in which both activity levels and sleep durations were associated with the risk of ventricular arrhythmia onset.24 While irregularity in day-to-day sleep behaviour has been found to increase the risk of cardiovascular events over the long term, this association may change when considering the risk of imminent ventricular arrhythmia.25–27 To our knowledge, we are the first to evaluate the short-term prognostic value of temporal changes in day-to-day sleep regularity for ventricular arrhythmia. The underlying mechanisms that explain the reduced day-to-day variability prior to ventricular arrhythmia remain unclear. There is strong evidence that physical activity influences sleep patterns, and patients who are more active on a given day may also experience reduced sleep the following night.28 However, in patients whose activity levels were consistently low prior to the arrhythmia, this effect may have vanished, leading to less variation in day-to-day sleep behaviour. Moreover, patients with a good functional capacity may have a more pronounced social jetlag (i.e. a greater difference in sleep timing between workdays and free days), while in the setting of decreased functional capacity, this may be less prominent.29 Future studies should examine the role of short-term sleep behaviour leading up to a ventricular arrhythmia, whether it serves as an independent prognostic factor or a reflection of underlying disease progression.
Continuous monitoring of physical behaviour generates large volumes of complex time series data. Analysing patterns within these datasets necessitates appropriate dimensionality reduction to aid analysis and interpretation without losing essential information. Expert-led time series feature extraction through basic statistical metrics (e.g. median, standard deviation, kurtosis, and skew) has been used to derive information from physical activity measurements.30,31 These traditional statistical methods, however, may overlook nuanced, non-linear relationships within the data. In contrast, deep neural networks can learn low-dimensional representations from complex data sets while preserving the richness and intrinsic information present in the data. These embedded representations, while lacking biological interpretability, serve as a low-dimension representation of the original data. We observed that these deep representations captured important behavioural signatures that enhanced the downstream prediction of arrhythmic events, particularly in intervals closer to the event. On the other hand, factor traversal analyses illustrated the complex behavioural dynamics associated with the risk of ventricular arrhythmia, which are challenging to interpret due to the non-linear patterns captured within the deep representations. As such, it is crucial that the robustness and reliability of these deep representations are investigated.
The SAFEHEART study incorporated several novelties in its study design. First, this study was completely decentralized in its design, with patient recruitment and all study procedures conducted without any in-person contact.32 While this approach arguably enhances accessibility for participants and facilitates recruitment, it does present challenges for comprehensive baseline examinations, such as echocardiography or blood testing. Second, patients were continuously monitored, day and night, for 12 months, while earlier studies have monitored physical behaviour for up to 14 days.2,19 Third, this was among the first studies to use two distinct wearable technologies within the same clinical study, which differed in sensor brands, algorithm architectures, and user requirements. Interestingly, despite the extensive monitoring period and participants being more remote from the study site, we observed high retention in the study, with 92% of patients eligible for analysis and a median of 253 valid days of behavioural data per patient. The successful harmonization of the collected data across devices, and the flexibility for patients to switch to their preferred device, is informative for future studies planning to combine digital health technologies.
Limitations
Our study has several limitations. First, the SAFEHEART study had a relatively small sample size and low number of events compared with large registries such as the UK Biobank. This limited sample size may reduce the statistical power of our models and increase the risk of overfitting. Related to this, there was a relatively young age and high percentage of secondary prevention ICD indications, which may not reflect a real-world, all-comer ICD population. Consequently, the generalizability of our findings needs to be examined using an independent dataset. In addition, whether patterns in physical behaviour are prognostic for ventricular arrhythmias beyond a population of ICD carriers, such as heart failure patients who do not fulfil the criteria for ICD implantation, remains to be answered. A second limitation to our study is the use of processed output from the accelerometer, instead of the underlying raw accelerometry output. Some of these metrics are created through the application of specific thresholds that rely on calibration studies, but pose a challenge when comparing metrics among different studies or populations, and may affect the generalisability of these findings.33 The use of autoencoders could be extended to include the raw daily outputs of the different devices without transformation, which could circumvent the need for threshold adjustments. Third, as dictated in the study protocol, we developed a prediction model that could provide an alarm within 28 days of the event.9 However, from the deep representations, we observed that in particular the 14 days prior to the event were relevant for the predictions. Future studies are needed to examine the optimal prediction window for arrhythmia prediction, ensuring a balance between the accuracy of the alarm and the practical reaction times needed. Moreover, appropriate ICD therapy, and in particular ATP, for a ventricular arrhythmia does not necessarily equate to actual sudden death, as ventricular arrhythmic events that trigger ICD therapy might have naturally self-terminated.34 Moreover, it is from this data unclear whether all participants received optimal pharmacological treatment. Finally, due to the observational nature of the study, the settings of the ICD were not harmonized across participants. These variations in ICD settings and medical therapy inherently impact each patient’s likelihood of receiving appropriate ICD therapy.
Conclusion
Trends in physical behaviour measured by wearable devices, in particular daily activity levels and day-to-day variation in sleep characteristics, were found to be associated with the risk of ventricular arrhythmia. There may be a role for real-time behavioural monitoring to guide clinicians towards more stringent observations of patients at increased risk; however, future studies should examine the robustness of these findings.
Supplementary Material
Contributor Information
Maarten Z H Kolk, Department of Clinical and Experimental Cardiology, Amsterdam UMC Location University of Amsterdam, Heart Center, Meibergdreef 9, 1105 AZ Amsterdam, The Netherlands; Amsterdam Cardiovascular Sciences, Heart Failure & Arrhythmias, Amsterdam UMC location AMC, Meibergdreef 9, 1105 AZ Amsterdam, The Netherlands.
Diana My Frodi, Department of Cardiology, Copenhagen University Hospital—Rigshospitalet, Inge Lehmanns Vej 7, 2100, Copenhagen, Denmark.
Joss Langford, Activinsights Ltd., Unit 11, Harvard Industrial Estate, Kimbolton, Huntingdon PE28 0NJ, UK; College of Life and Environmental Sciences, University of Exeter, Stocker Rd, Exeter EX4 4PY, UK.
Peter Karl Jacobsen, Department of Cardiology, Copenhagen University Hospital—Rigshospitalet, Inge Lehmanns Vej 7, 2100, Copenhagen, Denmark.
Niels Risum, Department of Cardiology, Copenhagen University Hospital—Rigshospitalet, Inge Lehmanns Vej 7, 2100, Copenhagen, Denmark.
Tariq O Andersen, Department of Computer Science, University of Copenhagen, Universitetsparken 1, 2100, Copenhagen, Denmark.
Hanno L Tan, Netherlands Heart Institute, Moreelsepark 1, 3511 EP, Utrecht, The Netherlands; Department of Clinical Medicine, Faculty of Health and Medical Sciences, University of Copenhagen, Blegdamsvej 3B, 2200, Copenhagen, Denmark.
Jesper Hastrup Svendsen, Department of Cardiology, Copenhagen University Hospital—Rigshospitalet, Inge Lehmanns Vej 7, 2100, Copenhagen, Denmark; Department of Clinical Medicine, Faculty of Health and Medical Sciences, University of Copenhagen, Blegdamsvej 3B, 2200, Copenhagen, Denmark.
Reinoud E Knops, Department of Clinical and Experimental Cardiology, Amsterdam UMC Location University of Amsterdam, Heart Center, Meibergdreef 9, 1105 AZ Amsterdam, The Netherlands; Amsterdam Cardiovascular Sciences, Heart Failure & Arrhythmias, Amsterdam UMC location AMC, Meibergdreef 9, 1105 AZ Amsterdam, The Netherlands.
Søren Zöga Diederichsen, Department of Cardiology, Copenhagen University Hospital—Rigshospitalet, Inge Lehmanns Vej 7, 2100, Copenhagen, Denmark.
Fleur V Y Tjong, Department of Clinical and Experimental Cardiology, Amsterdam UMC Location University of Amsterdam, Heart Center, Meibergdreef 9, 1105 AZ Amsterdam, The Netherlands; Amsterdam Cardiovascular Sciences, Heart Failure & Arrhythmias, Amsterdam UMC location AMC, Meibergdreef 9, 1105 AZ Amsterdam, The Netherlands.
Supplementary material
Supplementary material is available at European Heart Journal – Digital Health.
Funding
This research was supported by the Horizon 2020 European Union funding programme for research and innovation (grant number: Eurostars project E!113994- SafeHeart).
Data availability
The data underlying this article can be shared on reasonable request to the corresponding author. Code scripts are available at: https://github.com/DeepRiskAUMC/SafeHeart.
References
- 1. Marijon E, Narayanan K, Smith K, Barra S, Basso C, Blom MT, et al. The lancet commission to reduce the global burden of sudden cardiac death: a call for multidisciplinary action. Lancet 2023;402:883–936. [DOI] [PubMed] [Google Scholar]
- 2. Kolk MZH, Frodi DM, Andersen TO, Langford J, Diederichsen SZ, Svendsen JH, et al. Accelerometer-assessed physical behavior and the association with clinical outcomes in implantable cardioverter-defibrillator recipients: a systematic review. Cardiovasc Digit Health J 2022;3:46–55. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 3. Qiu S, Xing Z. Association between accelerometer-derived physical activity and incident cardiac arrest. Europace 2023;25:euad353. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 4. Elliott AD, Linz D, Mishima R, Kadhim K, Gallagher C, Middeldorp ME, et al. Association between physical activity and risk of incident arrhythmias in 402 406 individuals: evidence from the UK Biobank cohort. Eur Heart J 2020;41:1479–1486. [DOI] [PubMed] [Google Scholar]
- 5. Burch AE, Erath JW, Kutyifa V, Aßmus B, Bonderman D, Russo AM. Decline in physical activity in the weeks preceding sustained ventricular arrhythmia in women. Heart Rhythm O2 2020;1:283–287. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 6. Jamé S, Kutyifa V, Polonsky B, McNitt S, Al-Ahmad A, Moss AJ, et al. Predictive value of device-derived activity level for short-term outcomes in MADIT-CRT. Heart Rhythm 2017;14:1081–1086. [DOI] [PubMed] [Google Scholar]
- 7. Ginder C, Li J, Halperin JL, Akar JG, Martin DT, Chattopadhyay I, et al. Predicting malignant ventricular arrhythmias using real-time remote monitoring. J Am Coll Cardiol 2023;81:949–961. [DOI] [PubMed] [Google Scholar]
- 8. Shakibfar S, Krause O, Lund-Andersen C, Aranda A, Moll J, Andersen TO, et al. Predicting electrical storms by remote monitoring of implantable cardioverter-defibrillator patients using machine learning. Europace 2019;21:268–274. [DOI] [PubMed] [Google Scholar]
- 9. Frodi DM, Kolk MZH, Langford J, Andersen TO, Knops RE, Tan HL, et al. Rationale and design of the SafeHeart study: development and testing of a mHealth tool for the prediction of arrhythmic events and implantable cardioverter-defibrillator therapy. Cardiovasc Digit Health J 2021;2:S11–S20. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 10. von Elm E, Altman DG, Egger M, Pocock SJ, Gøtzsche PC, Vandenbroucke JP. The Strengthening the Reporting of Observational Studies in Epidemiology (STROBE) statement: guidelines for reporting observational studies. J Clin Epidemiol 2008;61:344–349. [DOI] [PubMed] [Google Scholar]
- 11. Campbell C, Gott A, Langford J, Sweetland C, Sweetland P, Chua J. GENEAclassify: Segmentation and Classification of Accelerometer Data. R package version 1.5.5. 2024. https://CRAN.R-project.org/package=GENEAclassify.
- 12. Moritz S, Bartz-Beielstein T. imputeTS: time series missing value imputation in R. R J 2017;9:207. [Google Scholar]
- 13. Kingma DP, Salimans T, Welling M. Improved variational inference with inverse autoregressive flow. ArXiv 2016;abs/1606.04934. [Google Scholar]
- 14. Higgins I, Matthey L, Pal A, Burgess CP, Glorot X, Botvinick MM, et al. beta-VAE: learning basic visual concepts with a constrained variational framework. In: International Conference on Learning Representations. 2016. [Google Scholar]
- 15. Selvaraju RR, Das A, Vedantam R, Cogswell M, Parikh D, Batra D. Grad-CAM: visual explanations from deep networks via gradient-based localization. Int J Comput Vision 2016;128:336–359. [Google Scholar]
- 16. Kolk MZH, Ruipérez-Campillo S, Alvarez-Florez L, Deb B, Bekkers EJ, Allaart CP, et al. Dynamic prediction of malignant ventricular arrhythmias using neural networks in patients with an implantable cardioverter-defibrillator. EBioMedicine 2023;99:104937. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 17. Ahmadi MN, Hamer M, Gill JMR, Murphy M, Sanders JP, Doherty A, et al. Brief bouts of device-measured intermittent lifestyle physical activity and its association with major adverse cardiovascular events and mortality in people who do not exercise: a prospective cohort study. Lancet Public Health 2023;8:e800–e810. [DOI] [PubMed] [Google Scholar]
- 18. Khurshid S, Weng LC, Nauffal V, Pirruccello JP, Venn RA, Al-Alusi MA, et al. Wearable accelerometer-derived physical activity and incident disease. NPJ Digit Med 2022;5:131. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 19. Rosman L, Lampert R, Sears SF, Burg MM. Measuring physical activity with implanted cardiac devices: a systematic review. J Am Heart Assoc 2018;7:e008663. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 20. Stehlik J, Schmalfuss C, Bozkurt B, Nativi-Nicolau J, Wohlfahrt P, Wegerich S, et al. Continuous wearable monitoring analytics predict heart failure hospitalization: the LINK-HF multicenter study. Circ Heart Fail 2020;13:e006513. [DOI] [PubMed] [Google Scholar]
- 21. Bonnesen MP, Frodi DM, Haugan KJ, Kronborg C, Graff C, Højberg S, et al. Day-to-day measurement of physical activity and risk of atrial fibrillation. Eur Heart J 2021;42:3979–3988. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 22. Omar M, Jensen J, Frederiksen PH, Videbæk L, Poulsen MK, Brønd JC, et al. Hemodynamic determinants of activity measured by accelerometer in patients with stable heart failure. JACC Heart Fail 2021;9:824–835. [DOI] [PubMed] [Google Scholar]
- 23. Meng Y, Zhang T, Ge X, Zheng Q, Feng T. Physical activity changes and related factors in chronic heart failure patients during the postdischarge transition period: a longitudinal study. BMC Cardiovasc Disord 2024;24:232. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 24. Frodi DM, Manea V, Diederichsen SZ, Svendsen JH, Wac K, Andersen TO. Using consumer-wearable activity trackers for risk prediction of life-threatening heart arrhythmia in patients with an implantable cardioverter-defibrillator: an exploratory observational study. J Pers Med 2022;12:942. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 25. Huang T, Mariani S, Redline S. Sleep irregularity and risk of cardiovascular events: the multi-ethnic study of atherosclerosis. J Am Coll Cardiol 2020;75:991–999. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 26. Nikbakhtian S, Reed AB, Obika BD, Morelli D, Cunningham AC, Aral M, et al. Accelerometer-derived sleep onset timing and cardiovascular disease incidence: a UK Biobank cohort study. Eur Heart J Digit Health 2021;2:658–666. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 27. Full KM, Huang T, Shah NA, Allison MA, Michos ED, Duprez DA, et al. Sleep irregularity and subclinical markers of cardiovascular disease: the multi-ethnic study of atherosclerosis. J Am Heart Assoc 2023;12:e027361. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 28. Zapalac K, Miller M, Champagne FA, Schnyer DM, Baird B. The effects of physical activity on sleep architecture and mood in naturalistic environments. Sci Rep 2024;14:5637. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 29. Ujma PP, Horváth CG, Bódizs R. Daily rhythms, light exposure and social jetlag correlate with demographic characteristics and health in a nationally representative survey. Sci Rep 2023;13:12287. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 30. Marzec L, Raghavan S, Banaei-Kashani F, Creasy S, Melanson EL, Lange L, et al. Device-measured physical activity data for classification of patients with ventricular arrhythmia events: a pilot investigation. PLoS One 2018;13:e0206153. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 31. Melin M, Hagerman I, Gonon A, Gustafsson T, Rullman E. Variability in physical activity assessed with accelerometer is an independent predictor of mortality in CHF patients. PLoS One 2016;11:e0153036. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 32. Inan OT, Tenaerts P, Prindiville SA, Reynolds HR, Dizon DS, Cooper-Arnold K, et al. Digitizing clinical trials. NPJ Digit Med 2020;3:101. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 33. Dibben GO, Gandhi MM, Taylor RS, Dalal HM, Metcalf B, Doherty P, et al. Physical activity assessment by accelerometry in people with heart failure. BMC Sports Sci Med Rehabil 2020;12:47. [DOI] [PMC free article] [PubMed] [Google Scholar]
- 34. Tung R, Zimetbaum P, Josephson ME. A critical appraisal of implantable cardioverter-defibrillator therapy for the prevention of sudden cardiac death. J Am Coll Cardiol 2008;52:1111–1121. [DOI] [PubMed] [Google Scholar]
Associated Data
This section collects any data citations, data availability statements, or supplementary materials included in this article.
Supplementary Materials
Data Availability Statement
The data underlying this article can be shared on reasonable request to the corresponding author. Code scripts are available at: https://github.com/DeepRiskAUMC/SafeHeart.





