mst.fit(X, y, freq, start, fixed.df=NA, plot.it=TRUE, trace=FALSE, ...)y is a matrix, its rows refer to
observations, and its columns to components of the multivariate
distribution. If y is a vector, it is converted to a one-column
matrix, and a scalar skew-t distribution iy.y.NA (default value) if df is a parameter
to be estimated.beta,Omega, alpha,
df of the type described below. The dp component of the returned
list from a previous call has the required format.trace=TRUE, details are printed. Default value is FALSE.msn.mle; in practice, the
start, the algorithm and the control parameters
can be passed.beta, Omega, alpha,
df. Here, beta is a matrix of regression coefficients with
dim(beta)=c(nrow(X),ncol(y)), Omega is a covariance matrix of
order ncol(y), alpha is a vector of shape parameters of length
ncol(y), df is a positive scalar.dp.beta, alpha, info.
Here, beta and alpha are the standard errors for the
corresponding point estimates;
info is the observed information matrix for the working parameter,
as explained below.mst.mle for its explanationtest and p.value, which are the value
of the likelihood ratio test statistic for normality (i.e. test that
all components of the shape parameter are 0), and the corresponding
p-value.(plot.it & missing(freq))==TRUE.
Three plots are produced, and the programs pauses between each two of them,
waiting for the The first plot uses the variable y if X is missing, otherwise
it uses the residuals from the regression.
The form of this plot depends on the value of d=ncol(y);
if d=1, an histogram is plotted with the fitted distribution
superimposed. If d>1, a matrix of scatter-plots is produced, with
superimposed the corresponding bivariate densities of the fitted
distribution.
The second plot has two panels, each representing a QQ-plot of Mahalanobis distances. The first of these refers to the fitting of a multivariate normal distribution, a standard statistical procedure; the second panel gives the corresponding QQ-plot of suitable Mahalanobis distances for the multivariate skew-normal fit.
The third plot is similar to the previous one, except that PP-plots are produced.
shape
parameter which regulates skewness; when shape=0, the skew-t
distribution reduces to the regular symmetric t-distribution.
When df=Inf the distribution reduces to the multivariate skew-normal
one; see dmsn. See the reference below for additional information.mst.fit
invokes mst.mle, while mst.fit displays the results
in graphical form.
See the documentation of mst.mle for details of the numerical
procedure for maximum likelihood estimation.mst.mle, msn.fitdata(ais, package="sn")
attach(ais)
# a simple-sample case
b <- mst.fit(y=cbind(Ht,Wt))
#
# a regression case:
a <- mst.fit(X=cbind(1,Ht,Wt), y=bmi)
#
# refine the previous outcome
a1 <- mst.fit(X=cbind(1,Ht,Wt), y=bmi, start=a$dp)Run the code above in your browser using DataLab