Send output to:
Browser Blue - Charts White
Browser Black/White
CSV
Data X:
23 26 17 27 13 12 13 13 22 20 31 30 NA NA NA NA 26 19 33 24 8 8 13 16 41 25 33 16 14 11 11 11 23 19 28 27 16 13 14 10 33 22 26 18 14 11 15 9 31 21 28 24 13 10 14 8 35 28 37 24 15 7 11 26 28 20 22 18 13 10 13 10 31 24 27 22 20 15 16 10 23 26 32 25 17 12 14 8 25 20 16 16 15 12 14 13 30 26 27 18 16 10 15 11 30 19 20 24 12 10 15 8 19 25 30 24 17 14 13 12 32 28 31 29 11 6 14 24 50 27 32 22 16 12 11 21 27 21 27 21 16 14 12 5 36 23 24 23 15 11 14 14 31 21 31 24 13 8 13 11 26 29 33 23 14 12 12 9 32 29 27 19 16 13 15 17 35 21 29 24 17 11 14 18 30 30 37 20 15 7 12 23 38 28 34 24 14 11 12 9 41 27 34 30 14 7 12 14 27 22 25 17 16 12 15 13 28 23 30 22 15 12 14 10 24 21 21 24 17 13 16 8 21 15 14 20 14 9 12 10 39 16 26 23 16 11 12 19 33 31 24 19 NA NA NA NA 28 18 24 22 15 12 14 11 47 25 25 24 16 15 16 16 26 25 33 20 16 12 15 12 25 15 26 24 10 6 12 11 34 24 23 26 8 5 14 11 30 20 27 24 17 13 13 10 30 24 31 24 14 11 14 13 25 28 31 24 10 6 16 14 19 15 15 21 14 12 12 8 28 20 26 22 12 10 14 11 39 33 27 29 16 6 15 11 20 13 13 23 16 12 13 13 30 21 32 22 16 11 16 15 31 24 27 25 8 6 16 15 19 23 23 23 16 12 12 16 25 21 24 24 15 12 12 12 52 33 41 30 8 8 16 12 33 24 37 24 13 10 12 17 22 23 23 24 14 11 15 14 32 20 30 20 13 7 12 15 17 14 17 16 16 12 13 12 31 25 26 27 19 13 12 13 20 34 19 13 19 14 14 7 29 22 35 29 14 12 14 8 37 25 22 27 15 6 11 16 21 21 27 24 13 14 10 20 23 21 21 24 10 10 12 14 30 21 28 23 16 12 11 10 21 24 24 22 15 11 16 16 24 22 32 26 11 10 14 11 40 28 39 26 9 7 14 26 20 18 18 21 16 12 15 9 33 23 31 23 12 7 15 15 20 16 19 20 12 12 14 12 26 24 30 28 14 12 13 21 22 27 37 29 14 10 11 20 32 18 20 16 13 10 16 20 13 11 15 25 15 12 12 10 28 26 34 28 17 12 15 15 32 26 25 24 14 12 14 10 27 23 22 24 9 10 14 9 32 20 34 24 NA NA NA NA 23 20 29 12 7 5 13 17 28 25 24 22 13 10 6 10 23 22 33 22 15 10 12 19 29 29 29 24 12 12 12 13 26 22 23 26 15 11 14 8 15 19 25 24 14 9 14 11 14 21 17 26 16 12 15 9 19 25 28 22 14 11 11 12 19 17 20 23 13 10 13 10 26 27 23 29 16 12 14 9 33 21 18 16 13 10 16 14 35 23 35 18 16 9 13 14 28 22 23 22 16 11 14 10 25 21 16 23 16 12 16 8 41 29 32 30 10 7 11 13 28 15 22 24 12 11 13 9 25 23 34 21 12 12 13 14 26 18 23 23 12 6 15 8 41 26 36 14 12 9 12 16 28 23 24 25 19 15 13 14 26 18 21 17 14 10 12 14 24 21 21 24 13 11 14 8 32 16 21 23 16 12 14 11 25 21 28 22 15 12 16 11 22 23 25 16 12 12 15 13 29 21 29 22 8 11 14 12 36 27 34 30 10 9 13 13 40 23 25 25 16 11 14 9 27 15 23 21 16 12 15 10 35 19 33 22 18 14 12 11 18 24 26 23 12 8 7 13 36 24 27 24 16 10 12 17 27 22 33 22 10 9 15 15 31 24 30 21 12 9 13 14 16 17 22 26 11 10 11 10 26 28 28 24 15 12 14 15 20 25 32 27 7 11 13 14
Names of X columns:
anderen positief negatief organisatie CONFSTATTOT CONFSOFTTOT STRESSTOT CESDTOT
Type of Correlation
kendall
pearson
spearman
kendall
Chart options
Title:
R Code
panel.tau <- function(x, y, digits=2, prefix='', cex.cor) { usr <- par('usr'); on.exit(par(usr)) par(usr = c(0, 1, 0, 1)) rr <- cor.test(x, y, method=par1) r <- round(rr$p.value,2) txt <- format(c(r, 0.123456789), digits=digits)[1] txt <- paste(prefix, txt, sep='') if(missing(cex.cor)) cex <- 0.5/strwidth(txt) text(0.5, 0.5, txt, cex = cex) } panel.hist <- function(x, ...) { usr <- par('usr'); on.exit(par(usr)) par(usr = c(usr[1:2], 0, 1.5) ) h <- hist(x, plot = FALSE) breaks <- h$breaks; nB <- length(breaks) y <- h$counts; y <- y/max(y) rect(breaks[-nB], 0, breaks[-1], y, col='grey', ...) } bitmap(file='test1.png') pairs(t(y),diag.panel=panel.hist, upper.panel=panel.smooth, lower.panel=panel.tau, main=main) dev.off() load(file='createtable') n <- length(y[,1]) n a<-table.start() a<-table.row.start(a) a<-table.element(a,paste('Correlations for all pairs of data series (method=',par1,')',sep=''),n+1,TRUE) a<-table.row.end(a) a<-table.row.start(a) a<-table.element(a,' ',header=TRUE) for (i in 1:n) { a<-table.element(a,dimnames(t(x))[[2]][i],header=TRUE) } a<-table.row.end(a) for (i in 1:n) { a<-table.row.start(a) a<-table.element(a,dimnames(t(x))[[2]][i],header=TRUE) for (j in 1:n) { r <- cor.test(y[i,],y[j,],method=par1) a<-table.element(a,round(r$estimate,3)) } a<-table.row.end(a) } a<-table.end(a) table.save(a,file='mytable.tab') ncorrs <- (n*n -n)/2 mycorrs <- array(0, dim=c(10,3)) a<-table.start() a<-table.row.start(a) a<-table.element(a,'Correlations for all pairs of data series with p-values',4,TRUE) a<-table.row.end(a) a<-table.row.start(a) a<-table.element(a,'pair',1,TRUE) a<-table.element(a,'Pearson r',1,TRUE) a<-table.element(a,'Spearman rho',1,TRUE) a<-table.element(a,'Kendall tau',1,TRUE) a<-table.row.end(a) cor.test(y[1,],y[2,],method=par1) for (i in 1:(n-1)) { for (j in (i+1):n) { a<-table.row.start(a) dum <- paste(dimnames(t(x))[[2]][i],';',dimnames(t(x))[[2]][j],sep='') a<-table.element(a,dum,header=TRUE) rp <- cor.test(y[i,],y[j,],method='pearson') a<-table.element(a,round(rp$estimate,4)) rs <- cor.test(y[i,],y[j,],method='spearman') a<-table.element(a,round(rs$estimate,4)) rk <- cor.test(y[i,],y[j,],method='kendall') a<-table.element(a,round(rk$estimate,4)) a<-table.row.end(a) a<-table.row.start(a) a<-table.element(a,'p-value',header=T) a<-table.element(a,paste('(',round(rp$p.value,4),')',sep='')) a<-table.element(a,paste('(',round(rs$p.value,4),')',sep='')) a<-table.element(a,paste('(',round(rk$p.value,4),')',sep='')) a<-table.row.end(a) for (iii in 1:10) { iiid100 <- iii / 100 if (rp$p.value < iiid100) mycorrs[iii, 1] = mycorrs[iii, 1] + 1 if (rs$p.value < iiid100) mycorrs[iii, 2] = mycorrs[iii, 2] + 1 if (rk$p.value < iiid100) mycorrs[iii, 3] = mycorrs[iii, 3] + 1 } } } a<-table.end(a) table.save(a,file='mytable1.tab') a<-table.start() a<-table.row.start(a) a<-table.element(a,'Meta Analysis of Correlation Tests',4,TRUE) a<-table.row.end(a) a<-table.row.start(a) a<-table.element(a,'Number of significant by total number of Correlations',4,TRUE) a<-table.row.end(a) a<-table.row.start(a) a<-table.element(a,'Type I error',1,TRUE) a<-table.element(a,'Pearson r',1,TRUE) a<-table.element(a,'Spearman rho',1,TRUE) a<-table.element(a,'Kendall tau',1,TRUE) a<-table.row.end(a) for (iii in 1:10) { iiid100 <- iii / 100 a<-table.row.start(a) a<-table.element(a,round(iiid100,2),header=T) a<-table.element(a,round(mycorrs[iii,1]/ncorrs,2)) a<-table.element(a,round(mycorrs[iii,2]/ncorrs,2)) a<-table.element(a,round(mycorrs[iii,3]/ncorrs,2)) a<-table.row.end(a) } a<-table.end(a) table.save(a,file='mytable2.tab')
Compute
Summary of computational transaction
Raw Input
view raw input (R code)
Raw Output
view raw output of R engine
Computing time
1 seconds
R Server
Big Analytics Cloud Computing Center
Click here to blog (archive) this computation