makeSECdistr {sn} | R Documentation |
Build an object which identifies a skew-elliptically contoured distribution (SEC), in the univariate and in the multivariate case. The term ‘skew-elliptical distribution’ is a synonym of SEC distribution.
makeSECdistr(dp, family, name, compNames)
dp |
a numeric vector (in the univariate case) or a list (in the
multivariate case) of parameters which identify the specific distribution
within the named |
family |
a character string which identifies the parametric family; currently, possible values are: "SN", "ESN", "ST", "SC". See ‘Details’ for additional information. |
name |
an optional character string with the name of the distribution. If missing, one is created. |
compNames |
in the multivariate case, an optional vector of character
strings with the names of the component variables; its length must be
equal to the dimensionality of the distribution being generated.
If missing, the components are named |
If dp
is a vector, a univariate distribution is built.
Alternatively, if dp
is a list, a multivariate distribution is
built. In both cases, the expected number of components of dp
depends on family
: it must be is 3
for "SN" and
"SC"; it must be 4
for "ESN" and "ST".
In the univariate case, the first three components of dp
represent
what in their specific distributions are denoted xi
(location),
omega
(scale, positive) and alpha
(slant); see functions
dsn
, dst
, dsc
for their
description.
The fourth component, when it exists, represents either tau
(hidden variable mean) for "ESN" or nu
(degrees of freedom)
for "ST". The names of the individual parameters are attached
to the components of dp
in the returned object.
In the multivariate case, dp
is a list with components having
similar role as in the univariate case, but xi=dp[[1]]
and
alpha=dp[[3]]
are now vectors and the scale parameter
Omega=dp[[2]]
is a symmetric positive-definite matrix.
For a multivariate distribution of dimension 1 (which can be created,
although a warning message is issued), Omega
corresponds to the
square of omega
in the univariate case.
Vectors xi
and alpha
must be of length ncol(Omega)
.
See also functions dmsn
, dmst
and
dmsc
.
The fourth component, when it exists, is a scalar with the same role as
in the univariate case.
In the univariate case alpha=Inf
is allowed, but in the multivariate
case all components of the vector alpha
must be finite.
For background information, see Azzalini and Capitanio (2014), specifically Chapers 2 and 4 for univariate cases, Chapters 5 and 6 for multivariate cases; Section 6.1 provides a general formulation of SEC distributions.
In the univariate case, an object of class SECdistrUv
;
in the multivariate case, an object of class SECdistrMv
.
See SECdistrUv-class
and SECdistrMv-class
for their description.
Adelchi Azzalini
Azzalini, A. with the collaboration of Capitanio, A. (2014). The Skew-Normal and Related Families. Cambridge University Press, IMS Monographs series.
The description of classes SECdistrUv-class
and
SECdistrMv-class
plot.SECdistr
for plotting and
summary.SECdistr
for summaries
Related functions dsn
, dst
, dsc
,
dmsn
, dmst
, dp2cp
Objects of class SECdistrMv-class
can be manipulated with
affineTransSECdistr
and conditionalSECdistr
f1 <- makeSECdistr(dp=c(3,2,5), family="SN", name="First-SN") show(f1) summary(f1) plot(f1) plot(f1, probs=c(0.1, 0.9)) # f2 <- makeSECdistr(dp=c(3, 5, -4, 8), family="ST", name="First-ST") f9 <- makeSECdistr(dp=c(5, 1, Inf, 0.5), family="ESN", name="ESN,alpha=Inf") # dp0 <- list(xi=1:2, Omega=diag(3:4), alpha=c(3, -5)) f10 <- makeSECdistr(dp=dp0, family="SN", name="SN-2d", compNames=c("u1", "u2")) # dp1 <- list(xi=1:2, Omega=diag(1:2)+outer(c(3,3),c(2,2)), alpha=c(-3, 5), nu=6) f11 <- makeSECdistr(dp=dp1, family="ST", name="ST-2d", compNames=c("t1", "t2"))