Databases Reference
In-Depth Information
If the mean squared errors are approximately the same, then our
model generalizes well and we're not in danger of overfitting. See
Figure 3-6 to see what this might look like. This approach is highly
recommended.
Figure 3-6. Comparing mean squared error in training and test set,
taken from a slide of Professor Nando de Freitas; here, the ground
truth is known because it came from a dataset with data simulated
from a known distribution
Other models for error terms
The mean squared error is an example of what is called a loss func‐
tion . This is the standard one to use in linear regression because it gives
us a pretty nice measure of closeness of fit. It has the additional de‐
sirable property that by assuming that ε s are normally distributed, we
can rely on the maximum likelihood principle. There are other loss
functions such as one that relies on absolute value rather than squar‐
ing. It's also possible to build custom loss functions specific to your
particular problem or context, but for now, you're safe with using mean
square error.
 
Search WWH ::




Custom Search