Hi,
I've had convergence problems with the multivariate student-t distribution, so I came along and found this
beauti
which lead me to think about Copulas in STAN.
1.
Let's consider the gumbel copula, since some Frank, Joe,... require discrete distributions.
case 'gumbel'
% uses Marshall-Olkin's method
if theta < 1
error('archrnd:BadGumbelParameter', ...
'THETA must be greater than or equal to 1 for the Gumbel copula.');
end
if theta == 1
y = rand(m,n); %independence
else
%uses positive, scaled by (cos(pi/2/theta))^theta, stable distribution
V = rand(m,1)*pi-pi/2;
W = -log(rand(m,1));
T = V + pi/2;
gamma = sin(T/theta).^(1/theta).*cos(V).^(-1).*((cos(V-T/theta))./W).^(1-1/theta);
y = exp( - (-log(rand(m,n))).^(1/theta)./(gamma*ones(1,n)) );
end
Considering the 'else' branch:
This is easy to implement in STAN. Note m is the sample size. Thus we would only need
to define two uniform variables for V, W and n parameters, normal(0,1) distributed
and take its CDF, since rand(m,n) is in [0,1].
2.
Multivariate Student-t
corrtest(theta); %test if R is a correlation matrix.
s = chi2rnd(nu,m,1);
y = tcdf(randn(m,n)*chol(theta).*( sqrt(nu./s)*ones(1,n) ),nu);
This is a 'MATT'-trick decomposition the multivariate student-t distribution to normal(0, 1)
ones.
3. Numerical solutions 'fixed-Talbot'
Would a implementation of numerical algorithm in STAN like the fixed talbot
to overcome the restrictions of not only discrete parameterizations, but also
allow other than Archimedean copulas?
----
Does somebody have experiences with this already? Comments are
welcome.
Thanks so much,
Andre
https://www.case.hu-berlin.de/events/events/Archive/Workshops/Copulae/talks/Hofert.pdf