tsdist_nmi: Normalized mutual information distance

View source: R/ts_dist.R

tsdist_nmiR Documentation

Normalized mutual information distance

Description

Calculates the normalized mutual information (NMI) and returns it as distance 1 - NMI.

Usage

tsdist_nmi(
  ts1,
  ts2,
  nbins = c("sturges", "freedman-diaconis", "scott"),
  normalization = c("sum", "min", "max", "sqrt"),
  method = "emp"
)

Arguments

ts1

Array. Time series 1

ts2

Array. Time series 2

nbins

The number of bins used for the discretization of both time series. It can be a positive integer or a string with one of the three rules "sturges" (default), "freedman-diaconis", or "scott".

normalization

The mutual information (I) normalization method. Options are "sum" (default) 1-(2I/(h1+h2)), "min" 1-(I/min(h1,h2)), "max" 1-(I/max(h1,h2)), and "sqrt" 1-(I/sqrt(h1*h2)).

method

The name of the entropy estimator used in the functions mutinformation() and entropy() from the infotheo package.

Value

Distance


ts2net documentation built on June 9, 2022, 9:06 a.m.