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

__Postestimation commands__

The following postestimation commands are available after **mprobit**:

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
* **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** predicted probabilities, linear predictions, and
standard errors
**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*] {*stub****** | *newvar* | *newvarlist*} [*if*] [*in*] [**,** *statistic*
__o__**utcome(***outcome***)**]

**predict** [*type*] {*stub****** | *newvarlist*} [*if*] [*in*] **,** __sc__**ores**

*statistic* Description
-------------------------------------------------------------------------
Main
__p__**r** predicted probabilities; the default
**xb** linear prediction
**stdp** standard error of the linear prediction
-------------------------------------------------------------------------
If you do not specify **outcome()**, **pr** (with one new variable specified),
**xb**, and **stdp** assume **outcome(#1)**.
You specify one or k new variables with **pr**, where *k* is the number of
outcomes.
You specify one new variable with **xb** and **stdp**.
These statistics are available both in and out of sample; type **predict**
*...* **if e(sample)** *...* if wanted only for the estimation sample.

__Menu for predict__

**Statistics > Postestimation**

__Description for predict__

**predict** creates a new variable containing predictions such as
probabilities, linear predictions, and standard errors.

__Options for predict__

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

**pr**, the default, calculates the predicted probabilities. If you do not
also specify the **outcome()** option, you specify k new variables, where
k is the number of categories of the dependent variable. Say that
you fit a model by typing **mprobit result x1 x2**, and **result** takes on
three values. Then you could type **predict p1 p2 p3** to obtain all
three predicted probabilities. If you specify the **outcome()** option,
you must specify one new variable. Say that **result** takes on the
values 1, 2, and 3. Typing **predict p1, outcome(1)** would produce the
same **p1**.

**xb** calculates the linear prediction, x_*i* a_*j*, for alternative *j* and
individual *i*. The index, *j*, corresponds to the outcome specified in
**outcome()**.

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

**outcome(***outcome***)** specifies the outcome for which the statistic is to be
calculated. **equation()** is a synonym for **outcome()**: it does not
matter which you use. **outcome()** or **equation()** can be specified using

**#1**, **#2**, ..., where **#1** means the first category of the dependent
variable, **#2** means the second category, etc.;

the values of the dependent variable; or

the value labels of the dependent variable if they exist.

**scores** calculates the equation-level score variables. The *j*th new
variable will contain the scores for the *j*th fitted equation.

__Syntax for margins__

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

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

*statistic* Description
-------------------------------------------------------------------------
default probabilities for each outcome
__p__**r** probability for a specified outcome
**xb** linear prediction for a specified outcome
**stdp** not allowed with **margins**
-------------------------------------------------------------------------
**pr** and **xb** default to the first outcome.

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
**. webuse sysdsn1**
**. mprobit insure age male nonwhite i.site**

Test that the coefficients on **2.site** and **3.site** are 0 in all equations
**. test 2.site 3.site**

Test that all coefficients in equation **Uninsure** are 0
**. test [Uninsure]**

Test that **2.site** and **3.site** are jointly 0 in the **Prepaid** equation
**. test [Prepaid]: 2.site 3.site**

Test that coefficients in equations **Prepaid** and **Uninsure** are equal
**. test [Prepaid=Uninsure]**

Predict probability that a person belongs to the **Prepaid** insurance
category
**. predict p1 if e(sample), outcome(2)**