**[R] probit postestimation** -- Postestimation tools for probit

__Postestimation commands__

The following postestimation commands are of special interest after
**probit**:

Command Description
-------------------------------------------------------------------------
**estat classification** report various summary statistics, including the
classification table
**estat gof** Pearson or Hosmer-Lemeshow goodness-of-fit test
**lroc** compute area under ROC curve and graph the curve
**lsens** graph sensitivity and specificity versus
probability cutoff
-------------------------------------------------------------------------
These commands are not appropriate after the **svy** prefix.

The following standard postestimation commands are also available:

Command Description
-------------------------------------------------------------------------
**contrast** contrasts and ANOVA-style joint tests of estimates
**estat ic** Akaike's and Schwarz's Bayesian information
criteria (AIC and BIC)
**estat summarize** summary statistics for the estimation sample
**estat vce** variance-covariance matrix of the estimators (VCE)
**estat** (svy) postestimation statistics for survey data
**estimates** cataloging estimation results
* **forecast** dynamic forecasts and simulations
* **hausman** Hausman's specification test
**lincom** point estimates, standard errors, testing, and
inference for linear combinations of coefficients
**linktest** link test for model specification
* **lrtest** likelihood-ratio test
**margins** marginal means, predictive margins, marginal
effects, and average marginal effects
**marginsplot** graph the results from margins (profile plots,
interaction plots, etc.)
**nlcom** point estimates, standard errors, testing, and
inference for nonlinear combinations of
coefficients
**predict** predictions, residuals, influence statistics, and
other diagnostic measures
**predictnl** point estimates, standard errors, testing, and
inference for generalized predictions
**pwcompare** pairwise comparisons of estimates
**suest** seemingly unrelated estimation
**test** Wald tests of simple and composite linear
hypotheses
**testnl** Wald tests of nonlinear hypotheses
-------------------------------------------------------------------------
* **forecast**, **hausman**, and **lrtest** are not appropriate with **svy** estimation
results. **forecast** is also not appropriate with **mi** estimation results.

__Syntax for predict__

**predict** [*type*] *newvar* [*if*] [*in*] [**,** *statistic* __nooff__**set** __rule__**s** **asif**]

*statistic* Description
-------------------------------------------------------------------------
Main
__p__**r** probability of a positive outcome; the default
**xb** linear prediction
**stdp** standard error of the linear prediction
* __de__**viance** deviance residual
__sc__**ore** first derivative of the log likelihood with respect
to xb
-------------------------------------------------------------------------
Unstarred statistics are available both in and out of sample; type
**predict** *...* **if e(sample)** *...* if wanted only for the estimation sample.
Starred statistics are calculated only for the estimation sample, even
when **if e(sample)** is not specified.

__Menu for predict__

**Statistics > Postestimation**

__Description for predict__

**predict** creates a new variable containing predictions such as
probabilities, linear predictions, standard errors, deviance residuals,
and equation-level scores.

__Options for predict__

+------+
----+ Main +-------------------------------------------------------------

**pr**, the default, calculates the probability of a positive outcome.

**xb** calculates the linear prediction.

**stdp** calculates the standard error of the linear prediction.

**deviance** calculates the deviance residual.

**score** calculates the equation-level score, the derivative of the log
likelihood with respect to the linear prediction.

**nooffset** is relevant only if you specified **offset(***varname***)** for **probit**.
It modifies the calculations made by **predict** so that they ignore the
offset variable; the linear prediction is treated as xb rather than
xb + offset.

**rules** requests that Stata use any rules that were used to identify the
model when making the prediction. By default, Stata calculates
missing for excluded observations.

**asif** requests that Stata ignore the rules and the exclusion criteria and
calculate predictions for all observations possible using the
estimated parameter from the model.

__Syntax for margins__

**margins** [*marginlist*] [**,** *options*]

**margins** [*marginlist*] **,** __pr__**edict(***statistic *...**)** [__pr__**edict(***statistic *...**)**
...] [*options*]

*statistic* Description
-------------------------------------------------------------------------
__p__**r** probability of a positive outcome; the default
**xb** linear prediction
**stdp** not allowed with **margins**
__de__**viance** not allowed with **margins**
__sc__**ore** not allowed with **margins**
-------------------------------------------------------------------------

Statistics not allowed with **margins** are functions of stochastic
quantities other than **e(b)**.

For the full syntax, see **[R] margins**.

__Menu for margins__

**Statistics > Postestimation**

__Description for margins__

**margins** estimates margins of response for probabilities and linear
predictions.

__Examples__

Setup
**. sysuse auto**
**. probit foreign weight mpg**

Obtain predicted probabilities
**. predict p**

Calculate and display summary statistics
**. summarize foreign p**

Use rules when making predictions
**. predict p2, rules**

Calculate and display summary statistics
**. summarize foreign p p2**

Ignore rules and exclusion criteria
**. predict p3, asif**

Calculate and display summary statistics
**. summarize foreign p p2 p3**