R: Tquest distance.

TquestDistance {TSdist} | R Documentation

## Tquest distance.

### Description

Computes the Tquest distance between a pair of numeric vectors.

### Usage

    TquestDistance(x, y, tx, ty, tau)

### Arguments

`x` | Numeric vector containing the first time series.
`y` | Numeric vector containing the second time series.
`tx` | If not constant, temporal index of series `x`.
`ty` | If not constant, temporal index of series `y`.
`tau` | Parameter (threshold) used to define the threshold passing intervals.

### Details

The TQuest distance represents the series based on a set of intervals that fulfill the following conditions:

1. All the values that the time series takes during these time intervals must be strictly above a user specified threshold `tau`.

2. They are the largest possible intervals that satisfy the previous condition.

The final distance between two series is defined in terms of the similarity between their threshold passing interval sets. For more information, see references.

### Value

`d` | The computed distance between the pair of series.

### Author(s)

Usue Mori, Alexander Mendiburu, Jose A. Lozano.

### References

Aßfalg, J., Kriegel, H., Kröger, P., Kunath, P., Pryakhin, A., & Renz, M. (2006). Similarity Search on Time Series based on Threshold Queries. In Proceedings of the 10th international conference on Advances in Database Technology (pp. 276-294).

Esling, P., & Agon, C. (2012). Time-series data mining. ACM Computing Surveys (CSUR), 45(1), 1–34.

### See Also

To calculate this distance measure using `ts`, `zoo` or `xts` objects see `TSDistances`. To calculate distance matrices of time series databases using this measure see `TSDatabaseDistances`.

### Examples

    # The objects example.series1 and example.series2 are two
    # numeric series of length 100 contained in the TSdist package.

    data(example.series1)
    data(example.series2)

    # For information on their generation and shape see help
    # page of example.series.

    help(example.series)

    # Calculate the Tquest distance assuming even sampling:

    TquestDistance(example.series1, example.series2, tau=2.5)

    # The objects example.series3 and example.series4 are two
    # numeric series of length 100 and 120 contained in the TSdist
    # package.

    data(example.series3)
    data(example.series4)

    # Calculate the Tquest distance for two series of different length:

    TquestDistance(example.series3, example.series4, tau=2.5)

[Package TSdist version 3.6 Index]