TopographicErrorHistogram (Apache Commons Math 3.6.1 API)

org.apache.commons.math3.ml.neuralnet.twod.util

## Class TopographicErrorHistogram

- java.lang.Object
- - org.apache.commons.math3.ml.neuralnet.twod.util.TopographicErrorHistogram

- All Implemented Interfaces:
    MapDataVisualization

      public class TopographicErrorHistogram
      extends Object
      implements MapDataVisualization

  Computes the topographic error histogram. Each bin will contain the number of data for which the first and second best matching units are not adjacent in the map.
  Since:
    3.6

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `TopographicErrorHistogram(boolean relativeCount, DistanceMeasure distance)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `double[][]` | `computeImage(NeuronSquareMesh2D map, Iterable<double[]> data)` Creates an image of the `data` metrics when represented by the `map`.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### TopographicErrorHistogram

          public TopographicErrorHistogram(boolean relativeCount,
                                   DistanceMeasure distance)

      Parameters:
        `relativeCount` - Whether to compute relative bin counts. If `true`, the data count in each bin will be divided by the total number of samples mapped to the neuron represented by that bin.
        `distance` - Distance.

  - ### Method Detail

    - #### computeImage

          public double[][] computeImage(NeuronSquareMesh2D map,
                                Iterable<double[]> data)

      Creates an image of the `data` metrics when represented by the `map`.
      Specified by:
        `computeImage` in interface `MapDataVisualization`
      Parameters:
        `map` - Map.
        `data` - Data.
      Returns:
        a 2D-array (in row major order) representing the metrics.

Copyright © 2003–2016 The Apache Software Foundation. All rights reserved.