Stata - $R^2$ interpretation How does Stata compute within, between and overall $R^2$ in fixed effect regressions?
How should I interpret each one? Assuming the data is country-country-year groups.
I have already looked at the Stata manual, and that hasn't cleared this up for me.
 A: Quick review of fixed effects
Let's assume we have $i=1, \ldots, n$ observations and $j=1, \ldots, m$ groups (such that each observation belongs to one and only one group). Furthermore, let's assume the linear model (where bold letters denote vectors):
$$ y_{ij} = \mathbf{x}_{ij} \cdot \mathbf{b} + u_j + \epsilon_{ij}$$
Let $\bar{y}_j$ and $\bar{\mathbf{x}}_j$ denote the group $j$ sample mean of the left hand side variable and right hand side variables respectively. The fixed effects estimator estimates $\mathbf{b}$ using the within group variation. It's equivalent to running the following regression:
$$ y_{ij} - \bar{y_j} = \left( \mathbf{x}_{ij} - \bar{\mathbf{x}}_j  \right)\cdot \mathbf{b}  + \epsilon_{ij}  $$
This is simply a regression with all the group means taken out! It's not that complicated.
Within, between, and overall $r^2$
Let $\hat{\mathbf{b}}$ be the coefficient estimate obtained by running a regression. Let $\operatorname{Corr}$ denote the sample correlation. In Stata's xtreg function


*

*The within $R^2$ is $ \operatorname{Corr} \left(y_{ij} - \bar{y}_j,  \left( \mathbf{x}_{ij} - \bar{\mathbf{x}}_j\right) \cdot \hat{\mathbf{b}} \right)^2 $
This is the $R^2$ if one ran a standard regression on data with the group means taken out. It's the square of the correlation between the demeaned left hand side variable $y_{ij} - \bar{y}_j$ and the forecast $ \left( \mathbf{x}_{ij} - \bar{\mathbf{x}}_j\right) \cdot \hat{\mathbf{b}}$ of this value based upon the within group variation.

*The between $R^2$ is $ \operatorname{Corr} \left(\bar{y}_j,   \bar{\mathbf{x}}_j \cdot \hat{\mathbf{b}} \right)^2 $ 
This is the $R^2$ of using estimate $\hat{\mathbf{b}}$ and the group mean $\bar{\mathbf{x}}_j$ of right hand side variables to predict the group mean of the left hand side variable $\bar{y}_j$.
Slight detail/nuance: observe that you're summing over $m$ rather than $n$ terms because there are $m$ groups. It would be the $R^2$ from the regression $\bar{y}_j = \bar{\mathbf{x}}_j \cdot \mathbf{b} + u_j$ except that our estimate $\hat{\mathbf{b}}$ is coming from the within group variation, fixed effects estimator, not the between group variation that you would get from that regression on group means.

*The overall $R^2$ is $ \operatorname{Corr} \left(y_{ij},  \mathbf{x}_{ij} \cdot \hat{\mathbf{b}} \right)^2 $
This is just the usual $R^2$.
Of course there are equivalent ways to write $R^2$ formulas so different documents etc... may say something different (but equivalent).
References:
Stata technical manual for xtreg p. 25
