Note: This page has been translated by MathWorks. Please click here

To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

`L = loss(mdl,tbl,ResponseVarName)`

`L = loss(mdl,tbl,Y)`

`L = loss(mdl,X,Y)`

`L = loss(___,Name,Value)`

returns
a scalar representing how well `L`

= loss(`mdl`

,`tbl`

,`ResponseVarName`

)`mdl`

classifies
the data in `tbl`

, when `tbl.ResponseVarName`

contains
the true classifications.

When computing the loss, `loss`

normalizes the
class probabilities in `tbl.ResponseVarNames`

to
the class probabilities used for training, stored in the `Prior`

property
of `mdl`

.

returns
the loss with additional options specified by one or more `L`

= loss(___,`Name,Value`

)`Name,Value`

pair
arguments, using any of the previous syntaxes.

Was this topic helpful?