Class JensenShannonEquiwidthDependence

  • All Implemented Interfaces:

    public class JensenShannonEquiwidthDependence
    extends java.lang.Object
    implements Dependence
    Jensen-Shannon Divergence is closely related to mutual information.

    The output value is normalized, such that an evenly distributed and identical distribution will yield a value of 1. Independent distributions may still yield values close to .25, though.

    TODO: Offer normalized and non-normalized variants?

    Erich Schubert
    • Constructor Detail

      • JensenShannonEquiwidthDependence

        protected JensenShannonEquiwidthDependence()
        Constructor - use STATIC instance.
    • Method Detail

      • dependence

        public <A,​B> double dependence​(NumberArrayAdapter<?,​A> adapter1,
                                             A data1,
                                             NumberArrayAdapter<?,​B> adapter2,
                                             B data2)
        Description copied from interface: Dependence
        Measure the dependence of two variables.

        This is the more flexible API, which allows using different internal data representations.

        Specified by:
        dependence in interface Dependence
        Type Parameters:
        A - First array type
        B - Second array type
        adapter1 - First data adapter
        data1 - First data set
        adapter2 - Second data adapter
        data2 - Second data set
        Dependence measure