Hello,
I have a panel data. The observations is the GDP data for provinces in different countries in different years
Due to the serial correlation, I try to use the "ivreghdfe" to get the autocorrelation-consistent standard error. The regression code is as follows:
However, many researchers suggest to cluster at coarsest level. Therefore, I try to use the following code to cluster at country level:
But I got the following error:
Is there any way to estimates autocorrelation-consistent standard errors while clustering at a higher level?
Many thanks
I have a panel data. The observations is the GDP data for provinces in different countries in different years
Code:
xtset province year
Code:
ivreghdfe gdp x, cluster(province year) bw(2)
Code:
ivreghdfe gdp x, cluster(country year) bw(2)
Code:
Error: cluster kernel-robust requires clustering on tsset panel & time vars. tsset panel var=gdlcode1; tsset time var=year; cluster vars=country1,year
Many thanks