Estimate the degrees of freedom and correlation parameters of the (bivariate) Student-t distribution by maximum likelihood estimation.
1 2 3
The density function is
f(y1, y2; nu, rho) = (1/(2*pi*sqrt(1-ρ^2))) * (1 + y1^2 + y_2^2 - 2*rho*y1*y2) / (nu*(1-rho^2))^((ν+2)/2)
for -1 < rho < 1, and real y1 and y2.
This VGAM family function can handle multiple responses, for example, a six-column matrix where the first 2 columns is the first out of three responses, the next 2 columns being the next response, etc.
An object of class
The object is used by modelling functions such as
The working weight matrices have not been fully checked.
The response matrix must have a multiple of two-columns. Currently, the fitted value is a matrix with the same number of columns and values equal to 0.0.
T. W. Yee, with help from Thibault Vatter.
Schepsmeier, U. and Stober, J. (2014). Derivatives and Fisher information of bivariate copulas. Statistical Papers 55, 525–542.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
nn <- 1000 mydof <- logloglink(1, inverse = TRUE) ymat <- cbind(rt(nn, df = mydof), rt(nn, df = mydof)) bdata <- data.frame(y1 = ymat[, 1], y2 = ymat[, 2], y3 = ymat[, 1], y4 = ymat[, 2], x2 = runif(nn)) summary(bdata) ## Not run: plot(ymat, col = "blue") fit1 <- vglm(cbind(y1, y2, y3, y4) ~ 1, # 2 responses, e.g., (y1,y2) is the 1st fam = bistudentt, # crit = "coef", # Sometimes a good idea data = bdata, trace = TRUE) coef(fit1, matrix = TRUE) Coef(fit1) head(fitted(fit1)) summary(fit1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.