Hi,
I want to reproduce the work of this paper. The paper fits a hierarchical ordered-logit model on the scores of judges in MMA fights.
Let y_n ∈ {7-10, 8-10, 9-10, 10-10, 10-9, 10-8, 10-7}
denote the score given by a judge.
There are N
observations of judges’ scores, J
judges and K
predictors.
The authors model y_n
using an ordered-logit regression with mean lambda_n
and thresholds indicating the cutoffs of each category denoted by t = (t1, ... , t6)
.
The goal is to estimate the spacing s
between the thresholds.
The fight start at 10-10. Any subsequent actions shift the predicted score probabilities away from 10-10 in either direction. Consequently, s_1
denotes the spacing between zero and the threshold of a fighter winning 10-9. Next s_2
denotes the space between the 10-9 and 10-8 thresholds. Finally, s_3
denotes the space between winning 10-8 and 10-7.
The vector t = (−s1 − s2 − s3, −s1 − s2, −s1, s1, s1 + s2, s1 + s2 + s3)
denotes the six cutoffs.
Each judge has an individual set of parameters, representing the value they attribute to each action, denoted by beta_j = (beta_{j,1}, . . ., beta_{j,K})
.
Summarised, the model is defined as follows:
How do I define t
using Stan syntax?
In addition, the example in the Stan guide focuses on estimating the cutoffs points, not the spacing between the cutoffs points.
Can you provide feedback on my model implementation for a single judge?
data {
int<lower=2> N; // number of observations
int<lower=1, upper=7> y_n[N]; // 1 = 7-10 and 7 = 10-7
int K; // number of predictors
matrix[N, K] X;
int i // number of thresholds = 3
}
parameters {
cholesky_factor_corr[K] L_Omega;
vector[K] mu;
vector[K] beta;
vector<lower=0>[K] sigma;
ordered<lower=0>[i-1] s;
}
transformed parameters {
cholesky_factor[K] L_Sigma = diag_pre_multiply(sigma, L_Omega);
vector[N] lambda = X * beta;
}
model {
mu ~ normal(0, 5);
sigma ~ normal(0, 2.5);
s ~ normal(0, 5);
L_Omega ~ lkj_cholesky(2);
for (k in 1:K) {
beta[k] ~ multi_normal_cholesky(mu[k], L_Sigma[k]);
}
for (n in 1:N) {
y[n] ~ ordered_logistic(lambda[n], t);
}
}