Last chance! 50% off unlimited learning
Sale ends in
indepTest
) for random vectors. The main
difference comes from the fact that critical values and p-values are
obtainted through the bootstrap/permutation methodology, since, here,
test statistics are not distribution-free.multIndepTest(x, d, m=length(d), N=1000, alpha=0.05, print.every = 100)
x
. It is required that sum(d)=ncol(x)
.m << p
especially when p
is large."print.every"
iterations. No progress is printed if it is nonpositive."multIndepTest"
returns an object of class
"indepTest"
whose attributes are: subsets
,
statistics
, critical.values
, pvalues
,
fisher.pvalue
(a p-value resulting from a combination � la
Fisher of the subset statistic p-values), tippett.pvalue
(a p-value
resulting from a combination � la Tippett of the subset
statistic p-values), alpha
(global significance level of the
test), beta
(1 - beta
is the significance level per
statistic), global.statistic
(value of the global Cram�r-von
Mises statistic derived directly from the independence empirical
copula process - see In
in the last reference) and
global.statistic.pvalue
(corresponding p-value).indepTest
,
serialIndepTest
,
multSerialIndepTest
,
dependogram
.## Consider the following example taken from
## Kojadinovic and Holmes (2008):
n <- 100
## Generate data
y <- matrix(rnorm(6*n),n,6)
y[,1] <- y[,2]/2 + sqrt(3)/2*y[,1]
y[,3] <- y[,4]/2 + sqrt(3)/2*y[,3]
y[,5] <- y[,6]/2 + sqrt(3)/2*y[,5]
nc <- normalCopula(0.3,dim=3)
x <- cbind(y,rcopula(nc,n),rcopula(nc,n))
x[,1] <- abs(x[,1]) * sign(x[,3] * x[,5])
x[,2] <- abs(x[,2]) * sign(x[,3] * x[,5])
x[,7] <- x[,7] + x[,10]
x[,8] <- x[,8] + x[,11]
x[,9] <- x[,9] + x[,12]
## Dimensions of the random vectors
d <- c(2,2,2,3,3)
## Run the test
test <- multIndepTest(x,d)
test
## Display the dependogram
dependogram(test,print=TRUE)
Run the code above in your browser using DataLab