A classificador linear is a type of aprendizado de máquina model used for classification tasks. It works by finding a combinação linear of features that can separate different classes in a dataset. The core idea is to create a decision boundary—a straight line in two-dimensional space (or a hyperplane in higher dimensions)—that best separates the data points of different classes.
Linear classifiers operate under the assumption that the classes can be separated by a linear function. For example, in a classificação binária problem, if we have two classes, the goal is to determine the weights that define a line (in 2D) or a hyperplane (in higher dimensions) such that data points from one class are on one side, and data points from the other class are on the opposite side.
Exemplos comuns de classificadores lineares incluem:
- Regressão Logística: Although it is used for binary classification, it predicts probabilities using a logistic function.
- Máquinas de Vetores de Suporte (SVM): A linear SVM finds the hyperplane that maximizes the margin between the closest data points of each class.
- Perceptron: An early type of rede neural que pode ser usado para classificação binária.
Classificadores lineares são particularmente eficazes quando os dados são linearmente separável, meaning that it can be perfectly divided by a straight line or a hyperplane. However, they may struggle with complex datasets where the relationship between features and classes is non-linear. In such cases, techniques like kernel methods or using more complex models (like neural networks) may be preferred.