Hi all. I need some help computing multidimensional pvalues of a multivariate data set. chisq.test(x[,1],x[,2])$p.value i need a command or loop that creates me a vector or a matrix (each variabe with each variable) would be even better for the p.values of the variables of a data set. something like chisq.test(x[,1:5],x[,2])$p.value or i=c(1,2,3) chisq.test(x[,i],x[,j])$p.value doesn't work would be pleased about every help. thanks in advance. lars -- View this message in context: http://www.nabble.com/chi.test-in-R-tf2592507.html#a7230474 Sent from the R help mailing list archive at Nabble.com.
downunder <larsfromspace at web.de> writes:> Hi all. > > I need some help computing multidimensional pvalues of a multivariate data > set. > > chisq.test(x[,1],x[,2])$p.value > > i need a command or loop that creates me a vector or a matrix (each variabe > with each variable) would be even better for the p.values of the variables > of a data set. > > something like > > chisq.test(x[,1:5],x[,2])$p.value or i=c(1,2,3) > chisq.test(x[,i],x[,j])$p.value doesn't worklook at mapply, or generally apply HTH, Jens