qrnegLogLikeOR2 {bqror} | R Documentation |
Negative sum of log-likelihood in the OR2 model
Description
This function computes the negative sum of log-likelihood in the OR2 model (ordinal quantile model with exactly 3 outcomes).
Usage
qrnegLogLikeOR2(y, x, gammacp, betaOne, sigmaOne, p)
Arguments
y |
observed ordinal outcomes, column vector of size |
x |
covariate matrix of size |
gammacp |
a row vector of cutpoints including (-Inf, Inf). |
betaOne |
a sample draw of |
sigmaOne |
a sample draw of |
p |
quantile level or skewness parameter, p in (0,1). |
Details
This function computes the negative sum of log-likelihood in the OR2 model where the error is assumed to follow an AL distribution.
Value
Returns the negative sum of log-likelihood.
References
Rahman, M. A. (2016). '"Bayesian Quantile Regression for Ordinal Models."' Bayesian Analysis, 11(1): 1-24. DOI: 10.1214/15-BA939
See Also
likelihood maximization
Examples
set.seed(101)
data("data25j3")
y <- data25j3$y
xMat <- data25j3$x
p <- 0.25
gammacp <- c(-Inf, 0, 3, Inf)
betaOne <- c(1.810504, 1.850332, 6.18116)
sigmaOne <- 0.9684741
output <- qrnegLogLikeOR2(y, xMat, gammacp, betaOne, sigmaOne, p)
# output
# 902.4045