Learn R Programming

sits (version 1.12.0)

sits_twdtw_classify: Find matches between a set of sits patterns and segments of sits tibble using TWDTW

Description

Returns the results of the TWDTW matching function. The TWDTW matching function compares the values of a satellite image time series with the values of known patters and tries to match each pattern to a part of the time series

The TWDTW (time-weighted dynamical time warping) is a version of the Dynamic Time Warping method for land use and land cover mapping using a sequence of multi-band satellite images. Methods based on dynamic time warping are flexible to handle irregular sampling and out-of-phase time series, and they have achieved significant results in time series analysis. In contrast to standard DTW, the TWDTW method is sensitive to seasonal changes of natural and cultivated vegetation types. It also considers inter-annual climatic and seasonal variability.

Usage

sits_twdtw_classify(data.tb = NULL, patterns.tb = NULL, bands = NULL,
  dist.method = "euclidean", alpha = -0.1, beta = 100, theta = 0.5,
  span = 0, keep = FALSE, start_date = NULL, end_date = NULL,
  interval = "12 month", overlap = 0.5)

Arguments

data.tb

A sits tibble to be classified using TWTDW.

patterns.tb

A tibble with known temporal signatures for the chosen classes.

bands

Names of the bands to be used for classification.

dist.method

Name of the method to derive the local cost matrix.

alpha

Steepness of the logistic function used for temporal weighting (a double value).

beta

Midpoint (in days) of the logistic function (an integer).

theta

Relative weight of the time distance compared to the dtw distance (a double value).

span

Minimum number of days between two matches of the same pattern in the time series (approximate).

keep

Keep internal values for plotting matches? (A logical value).

start_date

Start date of the classification period.

end_date

End date of the classification period.

interval

Period between two classifications in months.

overlap

Minimum overlapping between one match and the interval of classification.

Value

A dtwSat S4 object with the matches.

References

Maus V, Camara G, Cartaxo R, Sanchez A, Ramos FM, de Queiroz GR (2016). A Time-Weighted Dynamic Time Warping Method for Land-Use and Land-Cover Mapping. IEEE Journal of Selected Topics in Applied Earth Observations and Remote Sensing, 9(8):3729-3739, August 2016. ISSN 1939-1404. doi:10.1109/JSTARS.2016.2517118.

Examples

Run this code
# NOT RUN {
# Get a set of samples for the Mato Grosso state in Brazil
samples.tb <- sits_select_bands(samples_mt_9classes, ndvi, evi, nir, mir)
# obtain a set of patterns for these samples
patterns.tb <- sits_patterns(samples.tb)
# Get a point to classify
point.tb <- sits_select_bands(point_mt_6bands, ndvi, evi, nir, mir)
# find the matches between the patterns and the time series using the TWDTW algorithm
matches <- sits_twdtw_classify(point.tb, patterns.tb, bands = c("ndvi", "evi", "nir", "mir"),
                               alpha= -0.1, beta = 100, theta = 0.5, keep = TRUE)
# }

Run the code above in your browser using DataLab