regressionLayer
R2026b(Not recommended) Regression output layer
regressionLayer is not recommended. Use the trainnet
function and set the loss function to "mse" instead. For more
information, see Version
History.
To learn more about how to transition
trainNetwork, SeriesNetwork, and
DAGNetwork code to dlnetwork workflows, see Transition trainNetwork, SeriesNetwork, and DAGNetwork Code to dlnetwork Workflows.
Description
A regression layer computes the half-mean-squared-error loss for regression tasks.
returns a
regression output layer for a neural network as a layer = regressionLayerRegressionOutputLayer object.
sets the optional layer = regressionLayer(Name,Value)Name and ResponseNames
properties using name-value pairs. For example,
regressionLayer('Name','output') creates a regression layer
with the name 'output'. Enclose each property name in single
quotes.