Neural Network Toolbox™ Previous page   Next Page 
mseregec
 Provide feedback about this page

Mean squared error with regularization and economization performance function

Syntax

Description

mseregec is a network performance function. It measures network performance as the weighted sum of three factors: the mean squared error, the mean squared weights and biases, and the mean squared output.

mseregec(E,Y,X,PP) takes these arguments,

E
S x Q error matrix or N x TS cell array of such matrices
Y
S x Q error matrix or N x TS cell array of such matrices
X
Vector of weight and bias values
FP.reg
Importance of minimizing weights relative to errors
FP.econ
Importance of minimizing outputs relative to errors

and returns the mean squared error, plus FP.reg times the mean squared weights, plus FP.econ times the mean squared output.

mseregec('dy',E,Y,X,perf,FP) returns the derivative of perf with respect to Y.

mseregec('dx',E,Y,X,perf,FP) returns derivative of perf with respect to X.

mseregec('name') returns the name of this function.

mseregec('pnames') returns the name of this function.

mseregec('pdefaults') returns the default function parameters.

Examples

Here a two-layer feed-forward network is created with a one-element input ranging from -2 to 2, four hidden tansig neurons, and one purelin output neuron.

The network is given a batch of inputs P. The error is calculated by subtracting the output A from target T. Then the mean squared error is calculated using a ratio of 20/(20+1). (Errors are 20 times as important as weight and bias values.)

Network Use

You can create a standard network that uses mseregec with newff, newcf, or newelm.

To prepare a custom network to be trained with mseregec, set net.performFcn to 'mseregec'. This automatically sets net.performParam to mseregec's default performance parameters.

In either case, calling train or adapt results in mseregec's being used to calculate performance.

See newff or newcf for examples.

See Also

mse, mae, msereg


 Provide feedback about this page 

Previous page msereg nctool Next page

 © 1984-2008- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS