12.6 Ordered Logistic Distribution
12.6.1 Probability Mass Function
If K∈N with K>2, c∈RK−1 such that ck<ck+1 for k∈{1,…,K−2}, and η∈R, then for k∈{1,…,K}, OrderedLogistic(k | η,c)={1−logit−1(η−c1)if k=1,logit−1(η−ck−1)−logit−1(η−ck)if 1<k<K,andlogit−1(η−cK−1)−0if k=K. The k=K case is written with the redundant subtraction of zero to illustrate the parallelism of the cases; the k=1 and k=K edge cases can be subsumed into the general definition by setting c0=−∞ and cK=+∞ with logit−1(−∞)=0 and logit−1(∞)=1.
12.6.2 Sampling Statement
k ~
ordered_logistic
(eta, c)
Increment target log probability density with ordered_logistic_lpmf( k | eta, c)
dropping constant additive terms.
12.6.3 Stan Functions
real
ordered_logistic_lpmf
(ints k | vector eta, vectors c)
The log ordered logistic probability mass of k given linear predictors
eta, and cutpoints c.
int
ordered_logistic_rng
(real eta, vector c)
Generate an ordered logistic variate with linear predictor eta and
cutpoints c; may only be used in generated quantities block