Machine Learning Tutorial - Classification
๐ฏ Classification - Category Predict
Real Life:
๐ง Email: Spam ya Not Spam?
๐ฉบ Disease: Yes ya No?
๐ Fruit: Apple, Banana, Orange?
๐ค Gender: Male ya Female?
Examples
| Input | Output (Category) |
|---|---|
| Email text | Spam / Not Spam |
| Image | Cat / Dog |
| Symptoms | Disease A / B / C |
| Credit Score | Approve / Reject |
Common Algorithms:
- Decision Trees
- Random Forest
- Logistic Regression
- SVM
Example
from sklearn.tree import DecisionTreeClassifier
model = DecisionTreeClassifier()
model.fit(X, y)