sscopu(x, symmetry=FALSE, alpha=1.4, order=NULL, exclude=NULL, weights=NULL, id.basis=NULL, nbasis=NULL, seed=NULL, qdsz.depth=NULL, prec=1e-7, maxiter=30, skip.iter=dim(x)[2]!=2)
sscopu2(x, censoring=NULL, truncation=NULL, symmetry=FALSE, alpha=1.4, weights=NULL, id.basis=NULL, nbasis=NULL, seed=NULL, prec=1e-7, maxiter=30)
NULL
, it is set to dim(x)[2]
internally.id.basis
is specified.id.basis
is specified.smolyak.quad
for
the generation of quadrature.ssanova
for
notes on skipping theta iteration.sscopu
and sscopu2
return a list object of class
"sscopu"
. dsscopu
can be used to evaluate the
estimated copula density. A "copularization" process is applied to
the estimated density by default so the resulting marginal densities
are guaranteed to be uniform.cdsscopu
, cpsscopu
, and
cqsscopu
can be used to evaluate 1-D conditional pdf,
cdf, and quantiles.
sscopu
is essentially ssden
applied to
observations on unit cubes. Instead of variables in data frames,
the data are entered as a numerical matrix, and model complexity is
globally controlled by the highest order of interactions allowed in log density. sscopu2
further restricts the domain to the unit square, but
allows for possible censoring and truncation. With
censoring==0,1,2,3
, a data point $(x1,x2)$ represents
exact observation, $[0,x1]x{x2}$, ${x1}x[0,x2]$, or
$[0,x1]x[0,x2]$. With truncation
point $(t1,t2)$,
the sample is taken from $[0,t1]x[0,t2]$ instead of the unit
square.
With symmetriy=TRUE
, one may enforce the interchangeability
of coordinates so that $f(x1,x2)=f(x2,x1)$, say.
When (1,2)
is a row in exclude
, interaction terms
involving coordinates 1
and 2
are excluded.
## simulate 2-D data
x <- matrix(runif(200),100,2)
## fit copula density
fit <- sscopu(x)
## "same fit"
fit2 <- sscopu2(x,id=fit$id)
## symmetric fit
fit.s <- sscopu(x,sym=TRUE,id=fit$id)
## Kendall's tau and Spearman's rho
summary(fit); summary(fit2); summary(fit.s)
## clean up
## Not run: rm(x,fit,fit2,fit.s)
Run the code above in your browser using DataLab