2
$\begingroup$

Let's say I have a set of data and I modelled it using an ML algorithm. After I fit multiple models I achieve a certain level of accuracy. It doesn't get better beyond that point.

I want to prove using the error term that there are evident patterns and since there is predictability in error term therefore I can't model better than that.

One way to do that would be to visualize the error terms and see if there are any evident patterns or not. But a more robust way to that would be by using a statistical test.

Which statistical test can prove or disprove any evidence of patterns in residual?

$\endgroup$
4
  • $\begingroup$ You are trying to prove a negative $\endgroup$
    – Firebug
    Commented Jan 18, 2023 at 13:03
  • $\begingroup$ There is no such test. Predictability depends on the information you have. What is unpredictable with one information set can get much more predictable with more information. $\endgroup$ Commented Jan 18, 2023 at 13:13
  • $\begingroup$ @StephanKolassa say that you do not have any further information that can be fed in to the algorithm. There might be a way to prove that the model can't perform any better given the available set of information. $\endgroup$
    – Lopez
    Commented Jan 18, 2023 at 13:35
  • $\begingroup$ Do you mean, prove that there are not evident patterns and not predictability? It seems like you are describing a property of linear regression models (if you fit same linear model to residuals you get a null model, because if you didn't you could add it to the original model to make it better) that is not necessarily true of non-linear models -- because the model trained on data plus the model trained on the residuals may no longer belong to the same class of models. $\endgroup$
    – jwimberley
    Commented Jan 18, 2023 at 14:02

1 Answer 1

1
$\begingroup$

One approach is to use an F-test for goodness of fit (a description is in this question Linear regression: F-test for lack of fit (using ANOVA to test regression model) - intuition?). This requires data that has been sampled with the same conditions (e.g. in lots of scientific fields experimenters perform repetitions of the same experiment under the same circumstances, that gives an expression of the distribution of the error).

Or just use the ratio of the estimates of the error variance. The F-test can be unreliable, too easy with little power, if there are few degrees of freedom, and on the other hand it can be too harsh when a small amount of lack of fit is already significant.

Effectively it is a test to see whether the error terms in the model have zero expectation. You can also do this by visually inspecting the residuals.

In some models the error also relates to the expected value (except if there is potentially over-dispersion, but sometimes that might be excluded based on theoretical grounds). Examples are a binary classification or estimatiom of a Poisson distributed variable. In that case one can compare the observed likelihood or variance with the one that would be expected.

$\endgroup$

Not the answer you're looking for? Browse other questions tagged or ask your own question.