Description Usage Arguments Details Value Author(s) References See Also Examples
Return anomaly scores and path length of x
according to forest
.
1 | AnomalyScore(x, forest, ntree = forest$ntree, hlim = forest$hlim, appRange = F)
|
x |
a data frame of samples |
forest |
an object generated by |
ntree |
specifies the number of trees used to find the anomaly score, must be greater than 0 and smaller or equal to number of tree used in the model |
hlim |
evaluation tree height limit |
appRange |
boolean switch to apply application range |
AnomalyScore
passes each sample in x
through forest
to obtain expected path length. It then uses path length and parameter in forest
to determine anomaly score.
outF |
anomaly scores of samples in |
pathLength |
average path lengths of samples in |
Fei Tony Liu
Fei Tony Liu, Kai Ming Ting, and Zhi-Hua Zhou
Isolation Forest
IEEE International Conference on Data Mining 2008 (ICDM 08), Pisa, Italy, 2008.
http://www.gscit.monash.edu.au/gscitweb/loid.php?loid=905282&mimetype=application/pdf
1 2 3 4 5 6 7 8 | library(IsolationForest)
data(stackloss)
# train a model of Isolation Forest
tr<-IsolationTrees(stackloss,rFactor=0)
#evaluate anomaly score
as<-AnomalyScore(stackloss,tr)
# show anomaly score
as$outF
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.