I've encountered this question looking for "some guideline about how to manage the over-fitting problem". OP has enough specifics in their question for me to give a specific answer, but I tried looking for a canonical answer for this very, very common question, and couldn't find any...

Did I just happen to miss it?
Or maybe we don't want a canonical answer to such a broad question (I'd argue we do)?
Or maybe there are plenty of 'static' guides online in towardsdatascience, and we should focus on specific questions?

| |

Since https://datascience.stackexchange.com/ is pretty much a duplicate of https://stats.stackexchange.com/, don't forget to look at https://stats.stackexchange.com/.

E.g., here is a pretty canonical answer on https://stats.stackexchange.com/: What should I do when my neural network doesn't generalize well?. It overlaps a lot with yours. Also see Avoid overfitting in regression: alternatives to regularization and https://stats.stackexchange.com/questions/tagged/overfitting?tab=Votes

So much human time wasted resulting from duplicating https://stats.stackexchange.com/...

| |
  • $\begingroup$ Thank you for your link and input! Personally, I think that the way to go for ds.stackexachange is answering more specific cases while linking to a general resource (as discussed in Fnguyen's answer), and if that general resource is from Cross Validated - that's great! $\endgroup$ – Itamar Mushkin Jul 20 at 5:48

I don't know of such a canonical question/answer, but I will argue in favor of it.

The canonical question/answer gives us a clear place to point users to when we close a question as a duplicate. This approach is especially useful for questions that are very common for beginners in the area. With the canonical approach, we can curate a single high-quality question that captures the essence of the common issue, and know that we have one or more high-quality answers to it.

Such resources for beginners may exist on other sites, but we as a community cannot be 100% certain those sites will remain active and the content or links unchanged. With a canonical question/answer on this site, we can be certain that it will survive as long as StackExchange does.

Here is a nice meta post from the Chemistry community (my primary field and site) describing their approach to canonical questions and answers. It also lists canonical question/answer pairs that have been developed.


I am the author of one canonical answer


and one canonical question/answer pair.


This second question is a chemistry equivalent of a common question novices have. Novices think they are asking what appears to be a simple question, but the true answer amounts to the sum of the knowledge of the field. The overfitting question is similar. The problem is common. Novices may want a quick fix when there are actually a wide range of solutions depending on what you are trying to accomplish.

| |

In general this is one of those very basic questions that I struggle to think a topic more suited for a canonical question in "data science" than this.

However the one problem I see is that any good answer to such questions has two parts:

  1. One general truth about what overfitting is and what general ways there are to combat it regardless of used language, model, domain, problem, etc.

  2. A more specific operative insight into handling an overfitting problem that won't go away by simply using cross-validation, etc. Since data science SE is an applied topic I would expect good answers and questions here to deal with actual coding problems and therefore solutions would include actual code or library recommendations.

Obviously the second part is very hard to put into a canonical question, should we focus on python or R for example, do we recommend a train-test split or cross-validation (depends on the model and problem for me), etc.

In short

I'd argue for general overfitting questions there should be a canonical answer but there will still be a need for more specific overfitting questions and answers.

| |
  • 2
    $\begingroup$ I agree that there will still be an need for specific questions and answers, but they would benefit from a reference to a canonical q&a and from 'culling' the parts of the answer that is covered there. $\endgroup$ – Itamar Mushkin Jul 8 at 7:43

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .