Definition: Model fitting

Model fitting is the measure of how well a machine learning model generalizes data similar to that with which it was trained. A good model fit refers to a model that accurately approximates the output when it is provided with unseen inputs.

Fitting refers to adjusting the parameters in the model to improve accuracy. The process involves running an algorithm on data for which the target variable (“labeled” data) is known to produce a machine learning model. Then, the model’s outcomes are compared to the real, observed values of the target variable to determine the accuracy.

The next step involves adjusting the algorithm’s standard parameters in order to reduce the level of error and make the model more accurate when determining the relationship between the features and the target variable. This process is repeated several times until the model finds the optimal parameters to make predictions with substantial accuracy.

Overfitting and Underfitting

Overfitting negatively impacts the performance of the model on new data. It occurs when a model learns the details and noise in the training data too efficiently. When random fluctuations or the noise in the training data are picked up and learned as concepts by the model, the model “overfits”. It will perform well on the training set, but very poorly on the test set. This negatively impacts the model’s ability to generalize and make accurate predictions for new data.

Underfitting happens when the machine learning model cannot sufficiently model the training data nor generalize new data. An underfit machine learning model is not a suitable model; this will be obvious as it will have a poor performance on the training data.

svg viewer

Free Resources

Copyright ©2025 Educative, Inc. All rights reserved