6.9 Multivariate Probit
Mathematical representation
(6.17) |
where the ’s are not observed, but, similarly to binary Probit and Logit models, their signs are determined by the corresponding observed s.
- the model is estimated using observations
- is the value of equation ’s dependent variable for observation and it can take two values: 0 and 1,
- is a vector that stores the values of the independent variables for observation , as they appear in equation
- the same independent variable can appear in multiple equations, associated with different coefficients
- is a vector of parameters associated with equation ’s independent variables
- in total, there are parameters to be estimated
- the error terms jointly follow a multivariate Normal distribution with mean and covariance matrix
A more compact representation of the model is:
where:
and being the covariance matrix of : . For identification purposes, is normalized such that its diagonal elements are equal to one. Thus, is, in fact, a correlation matrix.
Priors
Parameter | Probability density function | Default hyperparameters |
, | ||
, | ||
The prior for
is transformed such that
and
is a proper correlation matrix.
| ||
An inverse-Wishart prior is used for a positive-definite, but otherwise unrestricted, matrix, . This prior is then internally transformed to a prior for , where is an diagonal matrix constructed by taking the inverse of the square root of the diagonal elements of : . |
The magnitude of the elements of the scale matrix,
, in the prior
for affects the
prior for only if
is not diagonal. The
degrees-of-freedom parameter, ,
in the prior for
can be used to control the dispersion of the implied prior density of
around
the prior expected value:
In both cases smaller values of allow larger deviations form . |
Due to an inverse-Wishart distribution being used as the prior for , the prior expected value of is . Although the prior for is transformed to a prior for such that the latter is a correlation matrix, due to simulation-based integration taking place in this transformation when is not diagonal, hyperparameter values that result into an expected value of that is far from satisfying the conditions necessary for it to be a correlation matrix may lead to numerical unstability issues when calculating the log-marginal likelihood of the model. It is, therefore, advised that is used to control the dispersion of around its expected value and is subsequently defined such that is close to being a proper correlation matrix (positive definite with values equal to one on the main diagonal). |
Syntax
y1 ~ x11 x12 … x1K,
y2 ~ x21 x22 … x2K,
…,
yM ~ xM1 xM2 … xMK }
, <options>
);
where:
- y1, y2, …, yM are the dependent variable names, as they appear in the dataset used for estimation
- xm1 xm2 xmK is a list of the independent variable names for equation , as they appear in the dataset used for estimation; when a constant term is to be included in an equation, this must be requested explicitly; such lists must be provided
All dependent variables, y1, y2, …, yM, in the dataset used for estimation must contain only two values: 0 and 1 (with 1 indicating “success" for the respective outcome). Observations with missing values in any dependent variable are dropped during estimation, but if a numerical value other than 0 and 1 is encountered, then an error is produced. |
The optional arguments for the multivarite Probit model are:9
Gibbs parameters
| |
"chains" | number of chains to run in parallel (positive integer); the default value is 1 |
"burnin" | number of burn-in draws per chain (positive integer); the default value is 10000 |
"draws" | number of retained draws per chain (positive integer); the default value is 20000 |
"thin" | value of the thinning parameter (positive integer); the default value is 1 |
"seed" | value of the seed for the random-number generator (positive integer); the default value is 42 |
Hyperparameters
| |
"m" | mean vector of the prior for ( vector); the default value is |
"P" | precision matrix of the prior for ( symmetric and positive-definite matrix); the default value is |
"S" | scale matrix of the prior for ( symmetric and positive-definite matrix); the default value is |
"n" | degrees-of-freedom parameter of the prior for (real number greater than or equal to ); the default value is |
Dataset and log-marginal likelihood
| |
"dataset" | the id value of the dataset that will be used for estimation; the default value is the first dataset in memory (in alphabetical order) |
"logML_CJ" | boolean indicating whether the Chib (1995)/Chib & Jeliazkov (2001) approximation to the log-marginal likelihood should be calculated (truefalse); the default value is false |
Reported Parameters
| variable_name | vector of parameters associated with the independent variables; these are broken into groups according to the equation in which the independent variables appear |
Stored values and post-estimation analysis
If a left-hand-side id value is provided when a multivariate Probit model is created, then the
following results are saved in the model item and are accessible via the ‘.’ operator:
Samples | a matrix containing the draws from the posterior of (across all equations, starting from the first equation) and the unique elements of |
ym$xm1,, | vectors containing the draws from the posterior of the parameters associated with variables xm1,,xmK, for (the names of these vectors are the names of the variables that were included in the right-hand side of equation , prepended by ym$, where ym is the name of the dependent variable in equation ; this is done so that the samples on the parameters associated with a variable that appears in more than one equations can be distinguished) |
Sigma_i_j | vectors containing the draws from the posterior of the unique elements of ; because is symmetric, only of its elements are stored (instead of all elements), including the elements that are restricted to be equal to one; i and j index the row and column of , respectively, at which the corresponding element is located |
Sigma | matrix that stores the posterior mean of |
logML | the Lewis & Raftery (1997) approximation of the log-marginal likelihood |
logML_CJ | the Chib (1995)/Chib & Jeliazkov (2001) approximation to the log-marginal likelihood; this is available only if the model was estimated with the "logML_CJ"=true option |
nchains | the number of chains that were used to estimate the model |
nburnin | the number of burn-in draws per chain that were used when estimating the model |
ndraws | the total number of retained draws from the posterior (chains draws) |
nthin | value of the thinning parameter that was used when estimating the model |
nseed | value of the seed for the random-number generator that was used when estimating the model |
Additionally, the following functions are available for post-estimation analysis (see section B.14):
- diagnostics()
- test()
- pmp()
- mfx()
- predict()
The multivariate Probit model uses the mfx() function to calculate and report the marginal effects of the independent variables on the probability of success for each of dependent variables. There are two types of marginal effects which can be requested by setting the "type" argument of the mfx() function equal to 1 or 2:
-
when "type"=1 the marginal effects for each of the outcomes are calculated marginally with respect to the values of the remaining dependent variables
-
when "type"=2 the marginal effects are calculated conditionally on the values of other dependent variables being equal to the values indicated by a vector z, passed to the mfx() function using the "opt" option. This vector must have dimension equal to and values equal to either 0 or 1. A value of 0 in the -th position of z indicates that the -th dependent variable is to restricted to 0 when calculating marginal effects on the remaining variables; a value of 1 indicates that the -th dependent variable is to be restricted to 1 when calculating these marginal effects.
The generic syntax for a statement involving the mfx() function after estimation of a multivariate Probit model is:
and:
for calculating these two types of marginal effects. The default value of the "type" option is 1. See the general documentation of the mfx() function (section B.14) for details on the other optional arguments.
Although BayES can calculate marginal effects for the multivariate Probit model at each observation, the calculations may take an excessive amount of time to complete. This is because the GHK simulator needs to be invoked at every observed data point, each time using all draws from the posterior, thus leading to an immense number of computations. |
The multivariate Probit model uses the predict() function to generate predictions of the probability of success for each of dependent variables. There are two types of predictions which can be requested by setting the "type" argument of the predict() function equal to 1 or 2:
-
when "type"=1 the predictions are generated for each of the dependent variables are calculated marginally with respect to the values of the remaining dependent variables
-
when "type"=2 the predictions are generated conditionally on the values of other dependent variables being equal to the values indicated by a vector z, passed to the predict() function using the "opt" option. This vector must have dimension equal to and values equal to either 0 or 1. A value of 0 in the -th position of z indicates that the -th dependent variable is to restricted to 0 when generating predictions for the remaining variables; a value of 1 indicates that the -th dependent variable is to be restricted to 1 when generating these predictions.
The generic syntax for a statement involving the predict() function after estimation of a random-effects binary Probit model is:
and:
);
for generating these two types of predictions effects. The default value of the "type" option is 1. See the general documentation of the predict() function (section B.14) for details on the other optional arguments.
Although BayES can generate summary statistics of the predictions for the multivariate Probit model at each observation, the calculations may take an excessive amount of time to complete. This is because the GHK simulator needs to be invoked at every observed data point, each time using all draws from the posterior, thus leading to an immense number of computations. |
Examples
Example 1
myData.constant = ones(rows(myData), 1);
myModel = mvprobit( {
y1 ~ constant x11 x12 x13 x14 x15,
y2 ~ constant x21 x22 x23 x24,
y3 ~ constant x21 x22 x23
} );
Example 2
myData.constant = ones(rows(myData), 1);
myModel = mvprobit( {
y1 ~ constant x11 x12 x13 x14 x15,
y2 ~ constant x21 x22 x23 x24,
y3 ~ constant x21 x22 x23
},
"m"=ones(15,1), "P"=0.01*eye(15,15), "n"=5,
"burnin"=20000, "draws"=40000, "thin"=4, "chains"=2,
"logML_CJ" = true
);
mfx( "point"="mean", "model"=myModel );
x_for_mfx = [
1.0,1.0,1.0,1.0,1.0,0.0, // values for the variables in the 1st equation
1.0,0.0,0.5,0.5,0.5, // values for the variables in the 2nd equation
1.0,0.0,0.5,0.5 // values for the variables in the 3rd equation
];
mfx( "point"=x_for_mfx, "model"=myModel );
mfx( "point"="mean", "model"=myModel, "type"=2, "opt"=[1,0,1]);
predict("prefix"=marg_);
predict("prefix"=cond_, "type"=2, "opt"=[1,0,1]);
9Optional arguments are always given in option-value pairs (eg. "chains"=3).