jsd: Estimate Jensen-Shannon divergence

View source: R/jsd.R

jsdR Documentation

Estimate Jensen-Shannon divergence

Description

Unified front-end for JSD estimation for continuous and discrete variables.

Usage

jsd(x, y, type = c("auto", "continuous", "discrete"), base = 2, ...)

Arguments

x

First vector.

y

Second vector.

type

One of '"auto"', '"continuous"', or '"discrete"'.

base

Logarithm base. Defaults to 2. Use 'exp(1)' for nats.

...

Additional arguments passed to the type-specific estimator.

Value

An object of class '"jsd_estimate"'.


jsdtools documentation built on March 31, 2026, 1:06 a.m.

Related to jsd in jsdtools...