Send output to:
Browser Blue - Charts White
Browser Black/White
CSV
Data X:
23 26 17 27 21 2 22 20 31 30 26 NA 26 19 33 24 22 NA 41 25 33 16 22 0 23 19 28 27 18 0 33 22 26 18 23 4 31 21 28 24 12 0 35 28 37 24 20 -1 28 20 22 18 22 0 31 24 27 22 21 1 23 26 32 25 19 0 25 20 16 16 22 3 30 26 27 18 15 -1 30 19 20 24 20 NA 19 25 30 24 19 4 32 28 31 29 18 1 50 27 32 22 15 0 27 21 27 21 20 -2 36 23 24 23 21 -4 31 21 31 24 21 NA 26 29 33 23 15 2 32 29 27 19 23 2 35 21 29 24 21 -4 30 30 37 20 25 2 38 28 34 24 9 2 41 27 34 30 30 0 27 22 25 17 20 NA 28 23 30 22 23 -3 24 21 21 24 16 2 21 15 14 20 16 0 39 16 26 23 19 4 33 31 24 19 25 NA 28 18 24 22 25 2 47 25 25 24 18 NA 26 25 33 20 23 2 25 15 26 24 21 NA 34 24 23 26 10 -4 30 20 27 24 14 3 30 24 31 24 22 NA 25 28 31 24 26 2 19 15 15 21 23 NA 28 20 26 22 23 NA 39 33 27 29 24 -1 20 13 13 23 24 -3 30 21 32 22 18 0 31 24 27 25 23 1 19 23 23 23 15 NA 25 21 24 24 19 NA 52 33 41 30 16 NA 33 24 37 24 25 NA 22 23 23 24 23 -3 32 20 30 20 17 NA 17 14 17 16 19 3 31 25 26 27 21 0 20 34 19 13 18 0 29 22 35 29 27 0 37 25 22 27 21 NA 21 21 27 24 13 3 23 21 21 24 8 NA 30 21 28 23 29 NA 21 24 24 22 28 0 24 22 32 26 23 2 40 28 39 26 21 -1 20 18 18 21 19 NA 33 23 31 23 19 3 20 16 19 20 20 NA 26 24 30 28 18 NA 22 27 37 29 19 NA 32 18 20 16 17 2 13 11 15 25 19 NA 28 26 34 28 25 2 32 26 25 24 19 NA 27 23 22 24 23 NA 32 20 34 24 26 NA 23 20 29 12 14 -2 28 25 24 22 28 NA 23 22 33 22 16 0 29 29 29 24 24 -2 26 22 23 26 20 0 15 19 25 24 12 NA 14 21 17 26 24 6 19 25 28 22 22 0 19 17 20 23 12 NA 26 27 23 29 22 -2 33 21 18 16 20 1 35 23 35 18 10 0 28 22 23 22 23 NA 25 21 16 23 17 NA 41 29 32 30 22 2 28 15 22 24 24 NA 25 23 34 21 18 NA 26 18 23 23 21 NA 41 26 36 14 20 2 28 23 24 25 20 NA 26 18 21 17 22 -3 24 21 21 24 19 NA 32 16 21 23 20 1 25 21 28 22 26 NA 22 23 25 16 23 NA 29 21 29 22 24 NA 36 27 34 30 21 NA 40 23 25 25 21 NA 27 15 23 21 19 NA 35 19 33 22 17 -4 18 24 26 23 20 NA 36 24 27 24 11 NA 27 22 33 22 8 NA 31 24 30 21 18 1 16 17 22 26 18 NA 26 28 28 24 19 0 20 25 32 27 19 NA
Names of X columns:
anderen positief negatief organisatie NUMERACYTOT DECTESTTOT
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