Skip to content

Commit

Permalink
fix doc
Browse files Browse the repository at this point in the history
  • Loading branch information
sth4nth committed Jan 24, 2019
1 parent f2d8141 commit 87260d5
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions chapter05/mlpClass.m
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
function [model, L] = mlpClass(X,y,k,lambda)
% Train a multilayer perceptron neural network for classification with backpropagation
function [model, L] = mlpClass(X, y, k, lambda)
% Train a multilayer perceptron neural network for multiclass classification with backpropagation
% logistic activation function is used.
% Input:
% X: d x n data matrix
% Y: p x n response matrix
% y: 1 x n label vector
% k: T x 1 vector to specify number of hidden nodes in each layer
% lambda: regularization parameter
% Ouput:
Expand Down
4 changes: 2 additions & 2 deletions chapter05/mlpReg.m
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
function [model, L] = mlpReg(X,y,k,lambda)
function [model, L] = mlpReg(X, y, k, lambda)
% Train a multilayer perceptron neural network for regression with backpropagation
% tanh activation function is used
% Input:
% X: d x n data matrix
% y: p x n response matrix
% y: 1 x n real value response vector
% k: T x 1 vector to specify number of hidden nodes in each layer
% lambda: regularization parameter
% Ouput:
Expand Down
2 changes: 1 addition & 1 deletion demo/ch05/mlp_demo.m
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
lambda = 1e-2;
[model, llh] = mlpClass(X,y,h,lambda);
[t,p] = mlpClassPred(model,X);
plot(llh);
figure;
plotClass(X,t);
figure;
plot(llh);

0 comments on commit 87260d5

Please sign in to comment.