bokbokbok.eval_metrics.multiclass_classification
QuadraticWeightedKappaMetric(XGBoost=False)
¶
Calculates the Weighted Cross Entropy Metric by applying a weighting factor alpha, allowing one to trade off recall and precision by up- or down-weighting the cost of a positive error relative to a negative error.
A value alpha > 1 decreases the false negative count, hence increasing the recall. Conversely, setting alpha < 1 decreases the false positive count and increases the precision.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
alpha
|
float
|
The scale to be applied. |
required |
XGBoost
|
Bool
|
Set to True if using XGBoost. We assume LightGBM as default use.
Note that you should also set |
False
|
Source code in bokbokbok/eval_metrics/classification/multiclass_eval_metrics.py
8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 |
|