Classification Flashcards
How is LDA similar to Logistic regression?
Both LDA and Logistic regression produce linear decision boundary.
True Positive
Actual = 1 | Prediction = 1
False Negative
Actual = 1 | Prediction = 0
When can accuracy be misleading?
When we have imbalanced data set, and prediction of minority class is critical.
What is Macro Precision (or Recall)
Average of Precision (or Recall) of all classes.
What is Confusion Matrix?
Confusion matrix is a matrix which shows the relation between the actual value and the predicted value.
Why do we only calculate Precision and Recall for positive class?
This is because our area of concern is positive class.
Spam Detection, Spam - Positive Anomaly Detection, Anomaly - Positive Disease Detection, Diseases - Positive
What is Weighted Precision (or Recall)?
Weighted Average of Precision (or Recall) of all classes.
How much accuracy is good?
It depends on the problem.
- In the case of medical data, even the accuracy of 99% is bad.
What is accuracy?
Correct Prediction/Total Prediction
Problem with accuracy
Accuracy does not tell about the nature of incorrect prediction.
Actual = 0 | Prediction = 1
Actual = 1 | Prediction = 0
The above both cases are different, however in terms of accuracy they are same.
Type I error
False Positive
When to use Logistic regression or LDA?
LDA assumes that the observations are drawn from a Gaussian distribution.
- When the data follows Gaussian distribution then LDA performs better than Logistic regression.
- If Gaussian assumptions are not met, Logistic regression can out perform LDA.
Type II error
False Negative
Precision
How accurate you are at predicting positives i.e., of all the classes that we predicted positive, how many actually are!
Precision = TP/(TP+FP)