I am looking for a confidence of model to predict well in a given situation.
So I have a model $f$ (generic, let's exemplify with a regression model of explicit form for brevity). It well fits on the train-set (by looking at say $r^2$), it well performs on the test set (by looking on RMSE). The fit is fine enough to predict with this model. Yet I want to know how confident am I to predict in this particular case, so while typically I look at the confidence $C$ of the model:
while now I want to know what is the confidence of predicting with this model (subject to $x$):
and I believe this shall strongly be related to presence of similar observations in the train/test sets and performance on similar observations.
Any hints on this welcomed.