sse
#
- mbgdml.losses.sse(errors)[source]#
Sum of squared errors.
\[SSE = \sum_{i=1}^n \left( \hat{y}_{i} - y_{i} \right)^2,\]where \(y_{i}\) is the true value, \(\hat{y}_{i}\) is the predicted value, and \(n\) is the number of data points.
- Parameters:
errors (
numpy.ndarray
) – Array of \(\hat{y} - y\) values. This will be flattened beforehand.- Returns:
Sum of squared errors.
- Return type: