In a regression tree, it is often assumed that each leaf is a Gaussian distribution $\mathcal{N}(\mu_i, \sigma)$, where $i$ is the index the leaf. Is $\sigma$ calculated as the standard deviation within a leaf or the standard deviation for the dataset?
If a tree is grown such that each leaf contains one instance (as is the case for bagged trees) then the within leaf calculation seems ill-posed. However, using the whole dataset seems like it could induce a lot of bias.
Is there something I am missing here?