File Exchange

image thumbnail


version (23.1 KB) by Zach Ziheng Wang
A toolbox used to learn linear binary classifiers with different loss functions.


Updated 14 May 2014

View License

This toolbox is used to learn linear binary classifiers through regularized risk minimization.
Specifically, it assumes a linear binary classifier y=sign(w'x+b), and the parameters are learned by minimizing the following objective function:
w*,b*=argmin 1/n sum l(y_i,w'x_i+b) + lambda/2*w'w
We use conjugate gradient descent method to solve the optimization problem.
1. The classifier can be learned using different loss functions such as square loss and logistic loss or any user defined loss.
2. The regularization parameter can be tuned through repeated k-fold cross validation or a separate validation set.
3. Regularization parameter can be tuned based on different criteria such as overall accuracy, average accuracy, average precision and area under roc curve
Note that if you want to use average precision and area under roc curve, make sure vlFeat toolbox ( is downloaded and included in the path

Cite As

Zach Ziheng Wang (2020). (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (0)


demo figure changed

MATLAB Release Compatibility
Created with R2012a
Compatible with any release
Platform Compatibility
Windows macOS Linux

Inspired: Truss displacement based on FEM