# Tag Info

### Micro Average vs Macro average Performance in a Multiclass classification setting

Micro- and macro-averages (for whatever metric) will compute slightly different things, and thus their interpretation differs. A macro-average will compute the metric independently for each class and ...
• 4,689
Accepted

### When is precision more important over recall?

For rare cancer data modeling, anything that doesn't account for false-negatives is a crime. Recall is a better measure than precision. For YouTube recommendations, false-negatives is less of a ...
• 3,470
Accepted

### What is the difference between bootstrapping and cross-validation?

Both cross validation and bootstrapping are resampling methods. bootstrap resamples with replacement (and usually produces new "surrogate" data sets with the same number of cases as the original ...

### Micro Average vs Macro average Performance in a Multiclass classification setting

This is the Original Post. In Micro-average method, you sum up the individual true positives, false positives, and false negatives of the system for different sets and the apply them to get the ...

### Micro Average vs Macro average Performance in a Multiclass classification setting

In a multi-class setting micro-averaged precision and recall are always the same. $$P = \frac{\sum_c TP_c}{\sum_c TP_c + \sum_c FP_c}\\ R = \frac{\sum_c TP_c}{\sum_c TP_c + \sum_c FN_c}$$ where c ...
Accepted

### Train/Test Split after performing SMOTE

When you use any sampling technique (specifically synthetic) you divide your data first and then apply synthetic sampling on the training data only. After you do the training, you use the test set (...
• 1,889

### How to define a custom performance metric in Keras?

You have to use Keras backend functions. Unfortunately they do not support the &-operator, so that you have to build a workaround: We generate matrices of the ...
• 381
Accepted

### How many features to sample using Random Forests

I think in the original paper they suggest using $\log_2(N +1$), but either way the idea is the following: The number of randomly selected features can influence the generalization error in two ways: ...
• 6,144

### When is precision more important over recall?

I can give you my real case when recall is more important: We have thousands of free customers registering in our website every week. The call center team wants to call them all, but it is imposible, ...
Accepted

### What are the disadvantages of accuracy?

A common complaint about accuracy is that it fails when the classes are imbalanced. For instance, if you get an accuracy of $98\%$, that sounds like a high $\text{A}$ in school, so you might be pretty ...
• 3,744
Accepted

### When do I have to use aucPR instead of auROC? (and vice versa)

Yes, you are correct that the dominant difference between the area under the curve of a receiver operator characteristic curve (ROC-AUC) and the area under the curve of a Precision-Recall curve (PR-...
• 6,778
Accepted

### Macro- or micro-average for imbalanced class problems

The choice of a metric depends on how you rank the importance of your classes and what you value from a classifier. Let's look at your example: For example if we have a data set with 90%-10% class ...
• 7,748
Accepted

### Micro-F1 and Macro-F1 are equal in binary classification and I don't know why

The difference between macro and micro averaging for performance metrics (such as the F1-score) is that macro weighs each class equally whereas micro weights each sample equally. If the distribution ...
• 181

### Neural Networks - Loss and Accuracy correlation

Log loss has the nice property that it is a differentiable function. Accuracy might be more important and is definitely more interpretable but is not directly usable in the training of the network due ...
• 9,258
Accepted

### Irregular Precision-Recall Curve

This is definitely possible. When you are reducing the threshold, you will never decrease the recall (you can only flag more of the positive examples as positive). Precision is looking at all the ...
• 9,258

### When is precision more important over recall?

Which is more important simply depends on what the costs of each error are. Precision tends to involve direct costs; the more false positives you have, the more cost per true positive you have. If ...
Accepted

### Is the F1 Score sensitive to the threshold?

Yes, it is. The formula: $$F_1 = \frac{2TP}{2TP + FP + FN}$$ There is no symmetry. You have only $TP$ in the nominator which means that $F_1=0$ if $threshold=1$.
• 4,043

### When is precision more important over recall?

Although in some situations recall may be more important than precision (or vice versa), you need both to get a more interpretable assessment. For instance, as noted by @SmallChess, in the medical ...
• 2,492
Accepted

### What is Continuous Ranked Probability Score (CRPS)?

CRPS is in a sense just the mean square error (MSE) of your predicted cumulative density function (CDF) and the true CDF. The CRPS generalizes the MAE (Mean Absolute Error) to the case of ...
• 2,981

### Do I need validation data if my train and test accuracy/loss is consistent?

You don't always need 3 separate datasets. You usually split a dataset into 3 if you are doing some parameter or hyperparameter tuning before choosing a final model. Tuning will usually add bias from ...
• 1,869

### When is precision more important over recall?

I had a tough time remembering the difference between precision and recall, until I came up with this mnemonic for myself: PREcision is to PREgnancy tests as reCALL is to CALL center. With a ...
Accepted

### Difference between learning_curve and validation_curve

Both curves show the training and validation scores of an estimator on the y-axis. A learning curve plots the score over varying numbers of training samples, while a validation curve plots the score ...
• 266

### What are the disadvantages of accuracy?

In general, the main disadvantage of accuracy is that it masks the issue of class imbalance. For example if the data contains only 10% of positive instances, a majority baseline classifier which ...
• 24.5k

### Neural Networks - Loss and Accuracy correlation

Loss is more general than accuracy. In classification, you can go to 100% accuracy, where all the labels are predicted correctly. But what about regression or forecasting? There is no definition of 0% ...
• 2,158

### What is the difference between bootstrapping and cross-validation?

Bootstrapping is any test or metric that relies on random sampling with replacement.It is a method that helps in many situations like validation of a predictive model performance, ensemble methods, ...
Accepted

### Micro Average vs Macro Average for Class Imbalance

The question is actually about understanding what it means to "take imbalance into account": Micro-average "takes imbalance into account" in the sense that the resulting ...
• 24.5k

### Micro Average vs Macro average Performance in a Multiclass classification setting

That's how it should be. I had the same result for my research. It seemed weird at first. But precision and recall should be the same while micro-averaging the result of multi-class single-label ...
Accepted

### Is Gini coefficient a good metric for measuring predictive model performance on highly imbalanced data

The Gini Coefficient can also be expressed in terms of the area under the ROC curve (AUC): G = 2*AUC -1 link. The ROC curve, on the other hand, is influenced by ...
• 6,144

### When is precision more important over recall?

Accumulation has a great answer on how you can come up with more examples explaining the importance of precision over recall and vice versa. Most of the other answers make a compelling case for the ...
• 61