### Navigation

- index
- modules |
- next |
- previous |
- statsmodels v0.2.0 documentation »
- Regression with Discrete Dependent Variable »
- scikits.statsmodels.discretemod.DiscreteResults »

# scikits.statsmodels.discretemod.DiscreteResults.margeff

`DiscreteResults.``margeff`(params=None, at='overall', method='dydx', atexog=None, dummy=False, count=False)

  Get marginal effects of the fitted model.

  Parameters: | params : array-like, optional The parameters. at : str, optional Options are: ‘overall’, The average of the marginal effects at each observation. ‘mean’, The marginal effects at the mean of each regressor. ‘median’, The marginal effects at the median of each regressor. ‘zero’, The marginal effects at zero for each regressor. ‘all’, The marginal effects at each observation. Note that if exog is specified, then marginal effects for all variables not specified by exog are calculated using the at option. method : str, optional ‘dydx’ - dy/dx - No transformation is made and marginal effects are returned. This is the default. ‘eyex’ - estimate elasticities of variables in exog – d(lny)/d(lnx) ‘dyex’ - estimate semielasticity – dy/d(lnx) ‘eydx’ - estimate semeilasticity – d(lny)/dx Note that tranformations are done after each observation is calculated. Semi-elasticities for binary variables are computed using the midpoint method. ‘dyex’ and ‘eyex’ do not make sense for discrete variables. atexog : array-like, optional Optionally, you can provide the exogenous variables over which to get the marginal effects. This should be a dictionary with the key as the zero-indexed column number and the value of the dictionary. Default is None for all independent variables less the constant. dummy : bool, optional If False, treats binary variables (if present) as continuous. This is the default. Else if True, treats binary variables as changing from 0 to 1. Note that any variable that is either 0 or 1 is treated as binary. Each binary variable is treated separately for now. count : bool, optional If False, treats count variables (if present) as continuous. This is the default. Else if True, the marginal effect is the change in probabilities when each observation is increased by one.
  Returns: | effects : ndarray the marginal effect corresponding to the input options

  Notes

  When using after Poisson, returns the expected number of events per period, assuming that the model is loglinear.

### Navigation

- index
- modules |
- next |
- previous |
- statsmodels v0.2.0 documentation »
- Regression with Discrete Dependent Variable »
- scikits.statsmodels.discretemod.DiscreteResults »