DTWBI-package {DTWBI} | R Documentation |

##
Imputation of Time Series Based on Dynamic Time Warping

### Description

Functions to impute large gaps within time series based on Dynamic Time Warping methods. It contains all required functions to create large missing consecutive values within time series and to fill them, according to the paper Phan et al. (2017), <DOI:10.1016/j.patrec.2017.08.019>. Performance criteria are added to compare similarity between two signals (query and reference).

### Details

Index of help topics:

DTWBI-package Imputation of Time Series Based on Dynamic Time
Warping
DTWBI_univariate DTWBI algorithm for univariate signals
compute.fa2 FA2
compute.fb Fractional Bias (FB)
compute.fsd Fraction of Standard Deviation (FSD)
compute.nmae Normalized Mean Absolute Error (NMAE)
compute.rmse Root Mean Square Error (RMSE)
compute.sim Similarity
dataDTWBI Six univariate signals as example for DTWBI
package
dist_afbdtw Adaptive Feature Based Dynamic Time Warping
algorithm
gapCreation Gap creation
local.derivative.ddtw Local derivative estimate to compute DDTW
minCost DTW-based methods for univariate signals

### Author(s)

Camille Dezecache, T. T. Hong Phan, Emilie Poisson-Caillault

Maintainer: Emilie Poisson-Caillault <emilie.poisson@univ-littoral.fr>

### References

Thi-Thu-Hong Phan, Emilie Poisson-Caillault, Alain Lefebvre, Andre Bigand. Dynamic time warping-
based imputation for univariate time series data. Pattern Recognition Letters, Elsevier, 2017,
<DOI:10.1016/j.patrec.2017.08.019>. <hal-01609256>

### Examples

```
# Load package dataset
data(dataDTWBI)
# Create a query and a reference signal
query <- dataDTWBI$query
ref <- dataDTWBI$query
# Create a gap within query (10% of signal size)
query <- gapCreation(query, rate = 0.1)
data <- query$output_vector
begin_gap <- query$begin_gap
size_gap <- query$gap_size
# Fill gap using DTWBI algorithm
results_DTWBI <- DTWBI_univariate(data, t_gap = begin_gap, T_gap = size_gap)
# Plot
plot(ref, type = "l")
lines(results_DTWBI$output_vector, col = "red", lty = "dashed")
# Compute the similarity of imputed vector and reference
compute.sim(ref, results_DTWBI$output_vector)
```

[Package

*DTWBI* version 1.1

Index]