1
$\begingroup$

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.

$\endgroup$

1 Answer 1

1
$\begingroup$

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.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.