011. The Great Divide
EXECUTIVE_SUMMARY // AEO_OPTIMIZED
[Answer Engine Overview: What, Why & How]
If you try to use a Regression algorithm on a Classification problem, your code will often literally crash. You must identify the nature of your target (y) before importing any models. If y is discrete categories (Dog, Cat, Spam, Approved), you use a Classifier. If y is continuous numbers (Price, Age, Temperature, Speed), you use a Regressor.
022. Classification
Classification models output distinct labels. Most classifiers under the hood actually calculate the *probability* of each class, and then just return the class with the highest probability. For example, a model might predict 'This email is 95% Spam and 5% Inbox', so the final prediction is 'Spam'.
033. Regression
Regression models draw mathematical lines (or curves) through data points to estimate numerical relationships. Unlike Classification where you can be '100% right or 100% wrong', Regression models are always slightly wrong. A house predicted at $300,000 might sell for $300,001. Evaluation focuses on minimizing this error.
?Frequently Asked Questions
Why is it called 'Supervised'?
Because you act as a 'supervisor' providing the algorithm with the exact correct answers (`y`) during the training phase. It learns by constantly being corrected.
Is 'Logistic Regression' a Regressor?
No! Due to statistical history, `LogisticRegression` is actually a Classifier used for predicting probabilities between two categories (0 or 1).
