Wild Speculation:
I am 70% confident that if we were smarter then we would not need it.
If you have some data that you (magically) know the likelihood and prior. Then you would have some uncertainty from the parameters in the model and some from the parameters, this would then change the form of the posterior for example from normal to a t-distribution to account for this extra uncertainty.
In the real world we assume a likelihood and guess a prior, and even with simple models such as y ~ ax + b we will usually model the residual errors as a normal distribution and thus thus loose some of the uncertainty, thus our residual errors are different in and out of sample.
Practical Reason
Also, a model with more* parameters will always have less residual errors (unless you screw up the prior) and thus the in sample predictions will seem better
Modern Bayesians have found two ways to solve this issue
- WAIC: Which uses information theory see how the posterior predictive distribution captures the generative process and penalizes for the effective number of parameters.
- PSIS-LOO: does a very fast version of LOO-CV where for each yi you factor that yi contribution to the posterior to get an out of sample posterior predictive estimate for yi.
Bayesian Models just like Frequentest Models are vulnerable to over fitting if they have many parameters and weak priors.
*Some models have parameters which constrains other parameters thus what I mean is "effective" parameters according to the WAIC or PSIS-LOO estimation, parameters with strong priors are very constrained and count as much less than 1.
See my comment at https://www.lesswrong.com/posts/Mw9if9wbfTBawynGs/?commentId=uEtuotdC6oD2H2FPw on a closely related question.
Briefly, if instead of using performance on a test set to judge future performance on real data, or to compare two models, you instead use a formal Bayesian approach that looks only at the training data, the quality of the answers from this formal Bayesian approach may depend very crucially on getting the Bayesian model specification (including priors for parameters) almost exactly right (in the sense of expression your true prior knowledge of the problem). And getting it that close to exactly right may be beyond your ability.
And in any case, we all know that there is a non-negligible chance that your program to do the Bayesian computations simply has a bug. So seeing how well you do on a held-out test set before launching your system to Jupiter is a good idea.
I'm not sure what you're asking here. The test set should of course be drawn from the same distribution as the future cases you actually care about. In practice, it can sometimes be hard to ensure that. But judging by performance on an arbitrary data set isn't an option, since performance in the future does depend on what data shows up in the future (for a classification problem, on both the inputs, and of course on the class labels). I think I'm missing what you're getting at....