Package elki.outlier.meta
Class FeatureBagging
- java.lang.Object
-
- elki.outlier.meta.FeatureBagging
-
- All Implemented Interfaces:
Algorithm,OutlierAlgorithm
@Title("Feature Bagging for Outlier Detection") @Reference(authors="A. Lazarevic, V. Kumar", title="Feature Bagging for Outlier Detection", booktitle="Proc. 11th ACM SIGKDD Int. Conf. on Knowledge Discovery in Data Mining", url="https://doi.org/10.1145/1081870.1081891", bibkey="DBLP:conf/kdd/LazarevicK05") public class FeatureBagging extends java.lang.Object implements OutlierAlgorithm
A simple ensemble method called "Feature bagging" for outlier detection.Since the proposed method is only sensible to run on multiple instances of the same algorithm (due to incompatible score ranges), we do not allow using arbitrary algorithms.
Reference:
A. Lazarevic, V. Kumar
Feature Bagging for Outlier Detection
Proc. 11th ACM SIGKDD Int. Conf. on Knowledge Discovery in Data Mining- Since:
- 0.4.0
- Author:
- Erich Schubert, Remigius Wojdanowski
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classFeatureBagging.ParParameterization class.-
Nested classes/interfaces inherited from interface elki.Algorithm
Algorithm.Utils
-
-
Field Summary
Fields Modifier and Type Field Description protected booleanbreadthCumulative sum or breadth first combinations.private intkThe parameters k for LOF.private static LoggingLOGThe logger for this class.protected intnumNumber of instances to use.private RandomFactoryrndRandom number generator for subspace choice.
-
Constructor Summary
Constructors Constructor Description FeatureBagging(int k, int num, boolean breadth, RandomFactory rnd)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description TypeInformation[]getInputTypeRestriction()Get the input type restriction used for negotiating the data query.private long[]randomSubspace(int alldim, int mindim, int maxdim, java.util.Random rand)Choose a random subspace.OutlierResultrun(Relation<NumberVector> relation)Run the algorithm on a data set.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface elki.outlier.OutlierAlgorithm
autorun
-
-
-
-
Field Detail
-
LOG
private static final Logging LOG
The logger for this class.
-
num
protected int num
Number of instances to use.
-
breadth
protected boolean breadth
Cumulative sum or breadth first combinations.
-
rnd
private RandomFactory rnd
Random number generator for subspace choice.
-
k
private int k
The parameters k for LOF.
-
-
Constructor Detail
-
FeatureBagging
public FeatureBagging(int k, int num, boolean breadth, RandomFactory rnd)Constructor.- Parameters:
k- k Parameter for LOFnum- Number of subspaces to usebreadth- Flag for breadth-first mergingrnd- Random generator
-
-
Method Detail
-
getInputTypeRestriction
public TypeInformation[] getInputTypeRestriction()
Description copied from interface:AlgorithmGet the input type restriction used for negotiating the data query.- Specified by:
getInputTypeRestrictionin interfaceAlgorithm- Returns:
- Type restriction
-
run
public OutlierResult run(Relation<NumberVector> relation)
Run the algorithm on a data set.- Parameters:
relation- Relation to use- Returns:
- Outlier detection result
-
randomSubspace
private long[] randomSubspace(int alldim, int mindim, int maxdim, java.util.Random rand)Choose a random subspace.- Parameters:
alldim- Number of total dimensionsmindim- Minimum number to choosemaxdim- Maximum number to choose- Returns:
- Subspace as bits.
-
-