Robust Standard Errors in Fixed Effects Model (using Stata) I'm trying to figure out the commands necessary to replicate the following table in Stata. This table is taken from Chapter 11, p. 357 of Econometric Analysis of Cross Section and Panel Data, Second Edition by Jeffrey M Wooldridge. Here I'm specifically trying to figure out how to obtain the robust standard errors (shown in square brackets) in column (2). I'm trying to do this in Stata. I was able to to get the conventional standard errors using the command

xtreg lpassen lfare ldist ldistsq y98 y99 y00, i(id) fe


. I was able to get column (1) with

xtreg lpassen lfare ldist ldistsq y98 y99 y00, i(id)


and the corresponding standard errors with

xtreg lpassen lfare ldist ldistsq y98 y99 y00, i(id) vce(robust)


. However, the command

xtreg lpassen lfare ldist ldistsq y98 y99 y00, i(id) fe vce(robust)


does not work for column (2). It gives results that are different from the book. Could someone explain how to obtain these standard
errors in Stata?

Note that the data to go along with this question can be found here: https://mitpress.mit.edu/books/econometric-analysis-cross-section-and-panel-data
Alternatively, you can load it directly into Stata using 

use http://www.stata.com/data/jwooldridge/eacsap/airfare, clear
Use -areg- in Stata, and the standard errors will come out as in the textbook. Specifically, the command 

areg lpassen lfare ldist ldistsq y98 y99 y00, absorb(id) vce(robust)


will produce the desired result.

-xtreg- with fixed effects and the -vce(robust)- option will automatically give standard errors clustered at the id level, whereas -areg- with -vce(robust)- gives the non-clustered robust standard errors. The latter seems to be what Wooldridge estimated.

Moreover, -xtreg- assumes that the number of -xtset- groups (id in your example) grows when more data is added to the sample. -areg-, however, assumes that the number of groups is fixed. I.e., the two estimators have different asymptotic properties. The point estimates will be identical, but standard errors will be different, sometimes substantially so.

Old versions of Stata (e.g. Stata 9) did not make the appropriate degrees of freedom adjustment when -xtreg, vce(robust)- was called, which is why you get a bigger standard error when specifying -version 9-. In fact, those standard errors are identical to -areg, absorb(id) vce(cluster id)- in newer versions of Stata.

As a side note, it is puzzling that Wooldridge got non-clustered robust standard errors when calling -xtreg, vce(robust)- in version 9, but perhaps I have a flawed understanding of what the call -version 9- does.

For more information on -xtreg- vs -areg-, see the blogpost and comments here.

(I recognize that this is a year-old thread, and that the question might have been answered on the Statalist. Consider my answer as "for future reference".)