library(knitr) opts_chunk$set(fig.width=11, fig.height=7, base64_images=F, fig.align="center", message=F, warning=F)
library(warpgroup) library(ggplot2)
Warpgroup was developed for LC/MS data but the approach is general and can be applied to any time series data. As an example we have performed consensus bound determination and intelligent bound filling on the follow echocardiogram data collected from sleep apnea patients.
ECG data was taken from:
T Penzel, GB Moody, RG Mark, AL Goldberger, JH Peter. The Apnea-ECG Database. Computers in Cardiology 2000;27:255-258. http://www.physionet.org/physiobank/database/apnea-ecg/
data(example_ekg) plot_peaks_bounds(eic.mat.s, ps)
We have chosen some regions of the EKGs for this example. Regions in samples 1 and 2 should produce the same group, and region 5 should be a separate group. Each group should have missing regions intelligently filled.
wg.bounds = warpgroup(ps, eic.mat.s, sc.aligned.lim = 4) for (i in seq(wg.bounds)) print(plot_peaks_bounds(eic.mat.s, wg.bounds[[i]]))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.