I am running a regression that requires a fixed effect variable, which we’ll call fe. When I manually remove the singleton observations, I am left with 22,000 observations.
Here is my code for filtering singletons:
gen fe_filter = 0
by fe, sort: egen tot = count(fe)
replace fe_filter = 1 if tot > 1
keep if fe_filter == 1
I then use areg:
areg y x1, absorb(fe)
and get an r squared of .88.
I then run reghdfe, again after manually dropping the singletons, again leaving n=22000. However it automatically drops another 12000 observations, leaving 10,000 observations and an r squared of .75.
Here is my code for reghfe
reghdfe y x1, absorb(fe)
Any idea why regdhfe might be dropping the extra 12000 observations?
Related Posts with Reghdfe Definition of Singleton
Multiply imputed dataset still contains missing valuesHi, I've attempted MI with the mi chained command on my dataset of around 6000 with mainly ordinal …
Probit margins "Factor not found in list of covariates"Dear Stata users, I am running a probit model with three binary indep. vars. and some other continu…
Using weights in regressionHi everyone, I want to run a regression using weights in stata. I already know which command to use …
Replicating ordered probit fixed and random effects estimations from Greene - Econometric Analysis, 8th EditionHello, I'm trying to replicate the estimations for ordered probit models present in Greene - Econome…
Sample size calculation (general or mixed linear model specific)Dear Statalisters I have a question that I hope you can help me with. I have searched the forums, …
Subscribe to:
Post Comments (Atom)
0 Response to Reghdfe Definition of Singleton
Post a Comment