Calculation of average marginal effects using -margin-
Margin is a user-written program that estimates average marginal effects, i.e. the sample average of the effects of partial or discrete changes in the explanatory variables. The presentation will compare the performance of margin and the official mfx. Margin is quicker because it computes the marginal effects and their standard errors analytically, using the appropriate cumulative distribution and density functions. If the dependent variable is a categorical or count variable, margin is more easy to use because it computes the marginal effects for each outcomes. It will also be shown that, unlike margin, mfx can produce misleading results after categorical models if the regression model includes a set of dummy variables which refer to the categories of a single categorical variable.