Class DistanceStddevOutlier<O>

  • Type Parameters:
    O - Object type
    All Implemented Interfaces:
    Algorithm, OutlierAlgorithm

    public class DistanceStddevOutlier<O>
    extends java.lang.Object
    implements OutlierAlgorithm
    A simple outlier detection algorithm that computes the standard deviation of the kNN distances.
    Since:
    0.5.0
    Author:
    Erich Schubert
    • Field Detail

      • distance

        protected Distance<? super O> distance
        Distance function used.
      • k

        protected int k
        Number of neighbors to get.
    • Constructor Detail

      • DistanceStddevOutlier

        public DistanceStddevOutlier​(Distance<? super O> distance,
                                     int k)
        Constructor.
        Parameters:
        distance - Distance function to use
        k - Number of neighbors to use
    • Method Detail

      • getInputTypeRestriction

        public TypeInformation[] getInputTypeRestriction()
        Description copied from interface: Algorithm
        Get the input type restriction used for negotiating the data query.
        Specified by:
        getInputTypeRestriction in interface Algorithm
        Returns:
        Type restriction
      • run

        public OutlierResult run​(Relation<O> relation)
        Run the outlier detection algorithm
        Parameters:
        relation - Relation to analyze
        Returns:
        Outlier score result