The SGDClassifier of scikit learn defines it as "Linear classifiers (SVM, logistic regression, etc.) with SGD training.". I understand from this that any Linear classifier can be used here. I want to know that how can we define a specific linear classifier to be used in the case of SGDClassifier.
1 Answer
The specific linear classifier can be defined with the loss function argument. The options are { ‘hinge’, ‘log’, ‘modified_huber’, ‘squared_hinge’, ‘perceptron’}. For example, hinge loss is equivalent to a linear SVM and log loss is equivalent to Logistic Regression.