plot_idtw: Plot the results from Dynamic Time Warping

plot.idtwR Documentation

Plot the results from Dynamic Time Warping

Description

Plot function for objects of type idtw, the output of dtw() and idtw() respectively.

Usage

## S3 method for class 'idtw'
plot(x, type = c("QC", "warp"), partial = NULL, selDim = 1, ...)
        
# an alias for plot_idtw
plot_idtw(x, type = c("QC", "warp"), partial = NULL, selDim = 1, ...)

## S3 method for class 'planedtw'
plot(x, type = c("QC", "warp"), partial = NULL, selDim = 1, ...)

# an alias for plot_planedtw
plot_planedtw(x, type = c("QC", "warp"), partial = NULL, selDim = 1, ...)

plotQC(x, Q, C, partial = NULL, selDim = 1, ...)

plotWarp(x, Q, C, partial = NULL, selDim = 1, ...)

Arguments

x

output from dtw(Q, C)

Q

one dimensional numeric vector

C

one dimensional numeric vector

type

character, one of c('QC', 'warp')

partial

list, the return value of dtw_partial(). Default = NULL, see dtw_partial() for details.

selDim

integer, gives the column index of the multivariate time series (matrices) to be plotted. (default = 1) If Q and C are univariate time series (vectors) then selDim is neglected.

...

Other arguments passed on to methods.

Details

The plot function visualizes the time warp and the alignment of the two time series. Also for partial alignments see dtw_partial()

Examples


Q <- cumsum(rnorm(100))
C <- Q[11:100] + rnorm(90, 0, 0.5)
tmp <- dtw(Q = Q, C = C, ws = 15, return_wp = TRUE, return_QC = TRUE) 

plot(tmp, type = 'QC')
plotQC(tmp)
plot(tmp, type = 'warp')
plotWarp(tmp)



IncDTW documentation built on March 18, 2022, 6:43 p.m.