*! version 1.0 - 09 Jan 2025
help appmlhdfe

Title

appmlhdfe -- Asymmetric Poisson regression with high dimensional fixed effects

Syntax

appmlhdfe
depvar
indepvars
[if] [in]
[, options]

expectile(#) estimate # expectile; default is expectile(.5) which corresponds to the conditional mean estimated by Poisson regression.

absorb(ppmlhdfe##absvar:absvars) categorical variables to be absorbed (fixed effects). Note that, unlike in ppmlhdfe, it is not possible to save separately save the estimates of each absorbed variable.

separation(string) algorithm used to drop
separated observations and their associated regressors as in ppmlhdfe.
Valid options are fe, ir, simplex, and mu (or any combination of those).
Although ir (iterated rectifier) is the only one that can systematically correct separation arising from both regressors and fixed effects, by default the first three methods are applied ( fe simplex ir).
See the ppmlhdfe paper as well as this guide for more information.

vce(vcetype) vcetype
may be robust (default) or cluster fvvarlist (allowing two- and multi-way clustering).

start(varname) vector of residuals to be used as starting values; see example below.

residual(varname) saves the residuals as varname; see example below.

strict check for separation in every iteration; by default, separated observations are dropped after the initial regression, and there are no further checks for separation.

tolerance tolerance used to determine convergence; the default is 1e-7.

iterate maximum number of iterations; the default is 50.

maxiter maximum number of iterations in each ppmlhdfe step; the default is 200.

nolog suppress the display of the iteration log.

weights are not allowed in the current version.

Description

appmlhdfe estimates conditional expectiles using Efron's (1992) asymmetric Poisson maximum likelihood estimator;
the expectiles are assumed to be an exponential function of a linear index, just like in standard Poisson regression. By
default, the expectile 0.5 is estimated, which corresponds to Poisson regression.

Acknowledgements

appmlhdfe is based on the powerful ppmlhdfe command by Correia et al. (2019); ppmlhdfe needs to be installed for appmlhdfe to run.

Remarks

appmlhdfe is not an official Stata command and was written by Matthew Clance and J.M.C. Santos Silva.
For further help and support, please contact jmcss@surrey.ac.uk. Please notice that this software is provided
as is, without warranty of any kind, express or implied, including but not limited to the warranties of
merchantability, fitness for a particular purpose and noninfringement. In no event shall the author be liable
for any claim, damages or other liability, whether in an action of contract, tort or otherwise, arising from,
out of or in connection with the software or the use or other dealings in the software.

Example

Load data

sysuse auto, clear

Basic use of appmlhdfe to estimate different expectiles

appmlhdfe price mpg, a(rep78 foreign) e(.1)

appmlhdfe price mpg, a(rep78 foreign) e(.9)

Use of appmlhdfe to estimate the 0.90 expectile, starting from the results of the estimation of the 0.85 expectile

appmlhdfe price mpg, a(rep78 foreign) e(.85) res(r)

appmlhdfe price mpg, a(rep78 foreign) e(.9) start(r)

Saved results

The output saved in e() by appmlhdfe is essentially the same that is saved by ppmlhdfe; more details can be seen in ppmlhdfe. Some additional results are listed below.

Scalars

e(converged) 1 if converged, 0 otherwise

e(Q) final value of the objective function (must be smaller than tolerance)

e(negative) percentage of negative residuals

e(R2) R-squared, computed as the square of the correlation between the dependent variable and its fitted values

References

Correia, S., Guimaraes, P., & Zylkin, T. (2020).
Fast Poisson Estimation with High-dimensional Fixed Effects,
Stata Journal 20(1), 95-115.

Efron, B. (1992).
Poisson Overdispersion Estimates Based on the Method of Asymmetric Maximum Likelihood,
Journal of the American Statistical Association, Vol. 87, No. 417, 98-107.

Last modified on 9 January 2025