Description Usage Arguments Details Value References Examples
ad: anomaly detection with normal probability density functions.
1 2 3 4 5 6 7 8 9 10 11 |
x |
A matrix of numeric features. |
... |
Optional parameters to be passed to ad.default. |
formula |
An object of class "formula": a symbolic description of the model to be fitted. |
data |
A data frame containing the features (predictors) and target. |
na.action |
A function specifying the action to be taken if NAs are found. |
y |
A vector of numeric target values, either 0 or 1, with 1 assumed to be anomalous. |
univariate |
Logical indicating whether the univariate pdf should be used. |
score |
String indicating which score to use in optimization:
|
steps |
Integer number of steps to take during epsilon optimization, default 1e3. |
amelie
implements anomaly detection with normal probability
functions and maximum likelihood estimates.
Features are assumed to be continuous, and the target is assumed to take
on values of 0
(negative case, no anomaly) or 1
(positive
case, anomaly).
The threshold epsilon
is optimized using the either the Matthews
correlation coefficient or F1 score.
Variance and covariance are computed using var
and cov
, where
denominator n-1
is used.
Algorithm details are described in the Introduction vignette.
The package follows the anomaly detection approach in Andrew Ng's course on machine learning.
An object of class ad
:
call |
The original call to |
univariate |
Logical indicating which pdf was computed. |
score |
The score that was used for optimization. |
epsilon |
The threshold value. |
train_mean |
Means of features in the training set. |
train_var |
Variances of features in the training set. If |
, holds the covariance matrix for the features.
val_score |
The score obtained on the validation data set. 0 to 1 for F1 score, -1 to 1 for Matthews correlation coefficient |
Matthews correlation coefficient
1 2 3 4 5 6 7 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.