R version 2.9.0 (2009-04-17) Copyright (C) 2009 The R Foundation for Statistical Computing ISBN 3-900051-07-0 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > x <- array(list(103.34 + ,98.60 + ,96.33 + ,102.60 + ,96.90 + ,96.33 + ,100.69 + ,95.10 + ,95.05 + ,105.67 + ,97.00 + ,96.84 + ,123.61 + ,112.70 + ,96.92 + ,113.08 + ,102.90 + ,97.44 + ,106.46 + ,97.40 + ,97.78 + ,123.38 + ,111.40 + ,97.69 + ,109.87 + ,87.40 + ,96.67 + ,95.74 + ,96.80 + ,98.29 + ,123.06 + ,114.10 + ,98.20 + ,123.39 + ,110.30 + ,98.71 + ,120.28 + ,103.90 + ,98.54 + ,115.33 + ,101.60 + ,98.20 + ,110.40 + ,94.60 + ,100.80 + ,114.49 + ,95.90 + ,101.33 + ,132.03 + ,104.70 + ,101.88 + ,123.16 + ,102.80 + ,101.85 + ,118.82 + ,98.10 + ,102.04 + ,128.32 + ,113.90 + ,102.22 + ,112.24 + ,80.90 + ,102.63 + ,104.53 + ,95.70 + ,102.65 + ,132.57 + ,113.20 + ,102.54 + ,122.52 + ,105.90 + ,102.37 + ,131.80 + ,108.80 + ,102.68 + ,124.55 + ,102.30 + ,102.76 + ,120.96 + ,99.00 + ,102.82 + ,122.60 + ,100.70 + ,103.31 + ,145.52 + ,115.50 + ,103.23 + ,118.57 + ,100.70 + ,103.60 + ,134.25 + ,109.90 + ,103.95 + ,136.70 + ,114.60 + ,103.93 + ,121.37 + ,85.40 + ,104.25 + ,111.63 + ,100.50 + ,104.38 + ,134.42 + ,114.80 + ,104.36 + ,137.65 + ,116.50 + ,104.32 + ,137.86 + ,112.90 + ,104.58 + ,119.77 + ,102.00 + ,104.68 + ,130.69 + ,106.00 + ,104.92 + ,128.28 + ,105.30 + ,105.46 + ,147.45 + ,118.80 + ,105.23 + ,128.42 + ,106.10 + ,105.58 + ,136.90 + ,109.30 + ,105.34 + ,143.95 + ,117.20 + ,105.28 + ,135.64 + ,92.50 + ,105.70 + ,122.48 + ,104.20 + ,105.67 + ,136.83 + ,112.50 + ,105.71 + ,153.04 + ,122.40 + ,106.19 + ,142.71 + ,113.30 + ,106.93 + ,123.46 + ,100.00 + ,107.44 + ,144.37 + ,110.70 + ,107.85 + ,146.15 + ,112.80 + ,108.71 + ,147.61 + ,109.80 + ,109.32 + ,158.51 + ,117.30 + ,109.49 + ,147.40 + ,109.10 + ,110.20 + ,165.05 + ,115.90 + ,110.62 + ,154.64 + ,96.00 + ,111.22 + ,126.20 + ,99.80 + ,110.88 + ,157.36 + ,116.80 + ,111.15 + ,154.15 + ,115.70 + ,111.29 + ,123.21 + ,99.40 + ,111.09 + ,113.07 + ,94.30 + ,111.24 + ,110.45 + ,91.00 + ,111.45 + ,113.57 + ,93.20 + ,111.75 + ,122.44 + ,103.10 + ,111.07 + ,114.93 + ,94.10 + ,111.17 + ,111.85 + ,91.80 + ,110.96 + ,126.04 + ,102.70 + ,110.50 + ,121.34 + ,82.60 + ,110.48 + ,124.36 + ,89.10 + ,110.66) + ,dim=c(3 + ,70) + ,dimnames=list(c('Uitvoer' + ,'TIP' + ,'cons') + ,1:70)) > y <- array(NA,dim=c(3,70),dimnames=list(c('Uitvoer','TIP','cons'),1:70)) > for (i in 1:dim(x)[1]) + { + for (j in 1:dim(x)[2]) + { + y[i,j] <- as.numeric(x[i,j]) + } + } > main = 'Kendall tau Correlation Plot' > #'GNU S' R Code compiled by R2WASP v. 1.0.44 () > #Author: Prof. Dr. P. Wessa > #To cite this work: AUTHOR(S), (YEAR), YOUR SOFTWARE TITLE (vNUMBER) in Free Statistics Software (v$_version), Office for Research Development and Education, URL http://www.wessa.net/rwasp_YOURPAGE.wasp/ > #Source of accompanying publication: Office for Research, Development, and Education > #Technical description: Write here your technical program description (don't use hard returns!) > 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='kendall') + 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', ...) + } > postscript(file="/var/www/html/rcomp/tmp/1n2r01261128543.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > pairs(t(y),diag.panel=panel.hist, upper.panel=panel.smooth, lower.panel=panel.tau, main=main) > dev.off() null device 1 > > #Note: the /var/www/html/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab > load(file="/var/www/html/rcomp/createtable") > > a<-table.start() > a<-table.row.start(a) > a<-table.element(a,'Kendall tau rank correlations for all pairs of data series',3,TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'pair',1,TRUE) > a<-table.element(a,'tau',1,TRUE) > a<-table.element(a,'p-value',1,TRUE) > a<-table.row.end(a) > n <- length(y[,1]) > n [1] 3 > cor.test(y[1,],y[2,],method='kendall') Kendall's rank correlation tau data: y[1, ] and y[2, ] z = 7.1584, p-value = 8.16e-13 alternative hypothesis: true tau is not equal to 0 sample estimates: tau 0.5848002 > for (i in 1:(n-1)) + { + for (j in (i+1):n) + { + a<-table.row.start(a) + dum <- paste('tau(',dimnames(t(x))[[2]][i]) + dum <- paste(dum,',') + dum <- paste(dum,dimnames(t(x))[[2]][j]) + dum <- paste(dum,')') + a<-table.element(a,dum,header=TRUE) + r <- cor.test(y[i,],y[j,],method='kendall') + a<-table.element(a,r$estimate) + a<-table.element(a,r$p.value) + a<-table.row.end(a) + } + } > a<-table.end(a) > table.save(a,file="/var/www/html/rcomp/tmp/29shl1261128543.tab") > > try(system("convert tmp/1n2r01261128543.ps tmp/1n2r01261128543.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 0.448 0.195 0.518