Bayesian estimation of the spatial autoregressive ordered probit model (SAR ordered probit model).
sarorderedprobit(formula, W, data, subset, ...)sar_ordered_probit_mcmc(y, X, W, ndraw = 1000, burn.in = 100, thinning = 1,
prior=list(a1=1, a2=1, c=rep(0, ncol(X)), T=diag(ncol(X))*1e12, lflag = 0),
start = list(rho = 0.75, beta = rep(0, ncol(X)),
phi = c(-Inf, 0:(max(y)-1), Inf)),
m=10, computeMarginalEffects=TRUE, showProgress=FALSE)
Returns a structure of class sarprobit
:
posterior mean of bhat based on draws
posterior mean of rho based on draws
posterior mean of phi based on draws
posterior mean of coefficients
fitted values
fitted reponse
\# of draws
beta draws (ndraw-nomit x nvar)
rho draws (ndraw-nomit x 1)
phi draws (ndraw-nomit x 1)
a1 parameter for beta prior on rho from input, or default value
a2 parameter for beta prior on rho from input, or default value
total time taken
1/max eigenvalue of W (or rmax if input)
1/min eigenvalue of W (or rmin if input)
'plevel' (default) for printing p-levels; 'tstat' for printing bogus t-statistics
lflag from input
1 for intercept term, 0 for no intercept term
a matrix containing log-determinant information (for use in later function calls to save time)
spatial weights matrix
regressor matrix
dependent variables. vector of discrete choices from 1 to J ({1,2,...,J})
design matrix
spatial weight matrix
number of MCMC iterations
number of MCMC burn-in to be discarded
MCMC thinning factor, defaults to 1.
A list of prior settings for \(\rho \sim Beta(a1,a2)\) and \(\beta \sim N(c,T)\). Defaults to diffuse prior for beta.
list of start values
Number of burn-in samples in innermost Gibbs sampler. Defaults to 10.
Flag if marginal effects are calculated. Defaults to TRUE. Currently without effect.
Flag if progress bar should be shown. Defaults to FALSE.
an object of class "formula
" (or one that can be coerced to that class): a symbolic description of the model to be fitted.
an optional data frame, list or environment (or object coercible by as.data.frame
to a data frame) containing the variables in the model.
If not found in data, the variables are taken from environment(formula), typically the environment from which sarprobit is called.
an optional vector specifying a subset of observations to be used in the fitting process.
additional arguments to be passed
Stefan Wilhelm <wilhelm@financial.com>
Bayesian estimates of the spatial autoregressive ordered probit model (SAR ordered probit model) $$ z = \rho W z + X \beta + \epsilon, \epsilon \sim N(0, I_n) $$ $$ z = (I_n - \rho W)^{-1} X \beta + (I_n - \rho W)^{-1} \epsilon $$ where y is a \((n \times 1)\) vector of discrete choices from 1 to J, \(y \in \{1,2,...,J\}\), where
\(y = 1\) for \(-\infty \le z \le \phi_1 = 0\)
\(y = 2\) for \(\phi_1 \le z \le \phi_2\)
...
\(y = j\) for \(\phi_{j-1} \le z \le \phi_j\)
...
\(y = J\) for \(\phi_{J-1} \le z \le \infty\)
The vector \(\phi=(\phi_1,...,\phi_{J-1})'\) \((J-1 \times 1)\) represents the cut points (threshold values) that need to be estimated. \(\phi_1 = 0\) is set to zero by default.
\(\beta\) is a \((k \times 1)\) vector of parameters associated with the \((n \times k)\) data matrix X.
\(\rho\) is the spatial dependence parameter.
The error variance \(\sigma_e\) is set to 1 for identification.
Computation of marginal effects is currently not implemented.
LeSage, J. and Pace, R. K. (2009), Introduction to Spatial Econometrics, CRC Press, chapter 10, section 10.2
sarprobit
for the SAR binary probit model