bayes_R2 and conditioning on random effects

Model-based is fine, but it should contain all the relevant sources of variance. In a mixed model these are the variances from the fixed effects from the random effects and the level 1 variance (\sigma^2).

So for mixed effects, I would expect a model-based R^2 to look like this:

\frac{V_{predicted}}{V_{fixed} + V_{random} + \sigma^2}

Then if V_{predicted} accounts from random effects, this R^2 gives the total variance accounted for the my model, and it V_{predicted} does not account for random effects, it is the R^2 accounted for only by the fixed effects.

Whereas currently the model-based R^2 is:

\frac{V_{predicted}}{V_{predicted} + \sigma^2}

Which is fine (I think) for when the prediction accounts for the random variance (re.form = NULL), but I’m not sure how to interpret this method when the prediction does not account for random effects (re.form = NA or fixed in some other way) - it is the R^2 in an assumed world where random effects are 0? Or some sort of partial-R^2 (with random effects partialled out)?