msn.mle(X, y, freq, start, trace=FALSE, method="BFGS", control=list(iter.max=150) )
y
is a matrix, rows refer to
observations, and columns to components of the multivariate
distribution. If y
is a vector, it is converted to a one-column
matrix, and a scalar skew-normal distribution is fy
.y
.beta
,Omega
, alpha
,
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 F
.optim
;
see the documentation of this function for its usage. Default value is
"BFGS"
.optim
;
see the documentation of this function for its usage.beta
, Omega
, alpha
.
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)
.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.optim
; see the documentation
of this function for explanation of its components.(Omega,alpha)
parametrization
adopted here is the one of Azzalini and Capitanio (1999).freq
is intended for use with grouped data,
setting the values of y
equal to the central values of the
cells; in this case the resulting estimate is an approximation
to the exact maximum likelihood estimate. If freq
is not
set, exact maximum likelihood estimation is performed.
The working parameter used in the maximization stage is
c(beta,alpha/omega)
, since a profile `deviance' -2*loglikelihood
for this parameter is actually used;
see Azzalini and Capitanio (1999) for details.
The optimizer optim
is called, supplying the gradient of
the profile deviance.
The function can take a vector y
as input; however the use of
sn.mle
is recommended in the scalar case.
Azzalini, A. and Capitanio, A. (1999). Statistical applications of the multivariate skew-normal distribution. J.Roy.Statist.Soc. B 61, 579--602.
dmsn
,sn.mle
,msn.fit
, optim
data(ais, package="sn")
attach(ais)
# a simple-sample case
b <- msn.mle(y=cbind(Ht,Wt))
#
# a regression case:
a <- msn.mle(X=cbind(1,Ht,Wt), y=bmi, control=list(x.tol=1e-6))
#
# refine the previous outcome
a1 <- msn.mle(X=cbind(1,Ht,Wt), y=bmi, control=list(x.tol=1e-9), start=a$dp)
Run the code above in your browser using DataLab