public class AUC2 extends Iced
Modifier and Type | Class and Description |
---|---|
static class |
AUC2.AUCBuilder |
static class |
AUC2.ThresholdCriterion
Criteria for 2-class Confusion Matrices
This is an Enum class, with an exec() function to compute the criteria
from the basic parts, and from an AUC2 at a given threshold index.
|
Modifier and Type | Field and Description |
---|---|
double |
_auc |
double[] |
_fps |
double |
_gini |
int |
_max_idx |
double |
_n |
int |
_nBins |
double |
_p |
double[] |
_ths |
double[] |
_tps |
static AUC2.ThresholdCriterion |
DEFAULT_CM |
static int |
NBINS |
Constructor and Description |
---|
AUC2(AUC2.AUCBuilder bldr) |
AUC2(Vec probs,
Vec actls)
Default bins, good answers on a highly unbalanced sorted (and reverse
sorted) datasets
|
Modifier and Type | Method and Description |
---|---|
double[][] |
buildCM(int idx) |
double[][] |
defaultCM() |
double |
defaultErr() |
double |
defaultThreshold() |
double |
fn(int idx) |
Function<java.lang.Integer,java.lang.Double> |
forCriterion(AUC2.ThresholdCriterion tc) |
double |
fp(int idx) |
double |
maxF1() |
static double |
perfectAUC(double[] ds,
double[] acts) |
static double |
perfectAUC(Vec vprob,
Vec vacts) |
double |
pr_auc() |
double |
threshold(int idx) |
double |
tn(int idx) |
double |
tp(int idx) |
asBytes, clone, copyOver, frozenType, read, readExternal, readJSON, reloadFromBytes, toJsonString, write, writeExternal, writeJSON
public final int _nBins
public final double[] _ths
public final double[] _tps
public final double[] _fps
public final double _p
public final double _n
public final double _auc
public final double _gini
public final int _max_idx
public static final AUC2.ThresholdCriterion DEFAULT_CM
public static final int NBINS
public AUC2(Vec probs, Vec actls)
public AUC2(AUC2.AUCBuilder bldr)
public double threshold(int idx)
public double tp(int idx)
public double fp(int idx)
public double tn(int idx)
public double fn(int idx)
public double maxF1()
public Function<java.lang.Integer,java.lang.Double> forCriterion(AUC2.ThresholdCriterion tc)
public double pr_auc()
public double[][] buildCM(int idx)
public double[][] defaultCM()
public double defaultThreshold()
public double defaultErr()
public static double perfectAUC(double[] ds, double[] acts)