R version 2.6.0 (2007-10-03) Copyright (C) 2007 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(107.7128539 + ,103.7153742 + ,110.4867578 + ,103.2675784 + ,94.26518847 + ,91.0402127 + ,86.54725876 + ,91.5506682 + ,101.3535721 + ,103.1174457 + ,101.6192851 + ,103.5170776 + ,99.64603189 + ,103.0772021 + ,109.6787099 + ,102.5407672 + ,94.54911034 + ,105.2931943 + ,112.6266645 + ,104.9433201 + ,85.17600032 + ,100.0513358 + ,92.45404496 + ,100.612316 + ,87.29580216 + ,88.34500266 + ,64.3924183 + ,89.17201443 + ,94.63764494 + ,104.3576643 + ,88.63638507 + ,104.3434487 + ,98.51912823 + ,112.9719188 + ,118.821131 + ,112.4841574 + ,98.0133073 + ,109.1553571 + ,96.13508564 + ,109.9542209 + ,109.2180588 + ,101.9588227 + ,93.75316585 + ,102.4508905 + ,115.6102653 + ,103.9308436 + ,109.9138197 + ,103.3890879 + ,111.9962942 + ,104.6620663 + ,97.6473181 + ,104.6291185 + ,92.76594094 + ,91.0402127 + ,81.49652852 + ,91.7375063 + ,97.32302267 + ,100.7036478 + ,94.94223039 + ,101.2877773 + ,94.95066913 + ,107.3454093 + ,114.0282407 + ,106.8884109 + ,100.5041372 + ,106.3450744 + ,107.5584646 + ,106.3048601 + ,90.79817856 + ,96.5212051 + ,86.46165316 + ,97.06239211 + ,94.57045233 + ,93.5588061 + ,61.73988971 + ,96.53839823 + ,104.445736 + ,101.9034452 + ,75.23512791 + ,104.3434487 + ,103.4294135 + ,114.0237988 + ,120.172651 + ,118.0350516 + ,108.1332281 + ,108.6908662 + ,86.11923077 + ,110.6081542 + ,105.0892033 + ,100.2208883 + ,92.56410131 + ,104.777117 + ,111.7496337 + ,107.5588196 + ,109.4436001 + ,111.766255 + ,103.742836 + ,116.337935 + ,94.83165149 + ,120.0249948 + ,92.95334688 + ,96.61410328 + ,73.44960239 + ,99.86496358 + ,106.4654884 + ,108.7174568 + ,83.96625 + ,112.337353 + ,110.1845127 + ,114.4946562 + ,108.6207159 + ,116.432019 + ,103.9517843 + ,104.0309382 + ,90.43921157 + ,106.6190617 + ,100.6369905 + ,102.0021975 + ,68.22766096 + ,106.6845542 + ,91.52296375 + ,101.2829593 + ,57.16656454 + ,107.3941217 + ,91.92476868 + ,109.0526921 + ,67.12384068 + ,114.9474577 + ,115.6528897 + ,130.3279398 + ,113.5276778 + ,133.5356618 + ,105.9780598 + ,116.0298221 + ,86.20483637 + ,120.1368973 + ,97.91285917 + ,108.8140087 + ,78.84412582 + ,113.0158357 + ,97.66354539 + ,130.0736122 + ,97.80566628 + ,135.0950749 + ,103.0115169 + ,105.8191343 + ,80.75331843 + ,109.970545 + ,93.32815877 + ,96.8927978 + ,66.34433782 + ,101.1728303 + ,112.3638534 + ,116.2485062 + ,82.13691993 + ,121.1576283 + ,112.4800234 + ,114.7080666 + ,94.39657455 + ,118.3407406 + ,105.7278449 + ,108.2384585 + ,88.63718494 + ,111.5415528 + ,105.415842 + ,116.6801093 + ,80.29805016 + ,121.7250211 + ,98.79761393 + ,103.7933091 + ,52.68470588 + ,111.465018 + ,97.97656957 + ,116.0952339 + ,71.23826174 + ,123.1125447 + ,121.3989682 + ,135.0614001 + ,102.4902647 + ,140.3433622 + ,104.9473271 + ,112.4996914 + ,73.0215744 + ,118.1750972 + ,104.5976729 + ,115.379539 + ,70.79507353 + ,121.9330371 + ,99.85471468 + ,137.3295644 + ,90.86992793 + ,144.638683 + ,100.2951889 + ,114.3393628 + ,76.92401183 + ,120.3391964 + ,89.76744588 + ,98.00757592 + ,59.83831243 + ,103.6017255 + ,101.255266 + ,115.6691947 + ,74.72813317 + ,121.6422588 + ,106.6369053 + ,118.7628633 + ,88.28372041 + ,123.8548253 + ,102.8025686 + ,116.337935 + ,78.72603847 + ,122.3291396 + ,104.3851093 + ,111.5707096 + ,71.90870164 + ,117.2409067 + ,85.13306832 + ,94.13811759 + ,49.66631127 + ,100.996999 + ,95.26369331 + ,114.9214769 + ,70.53293242 + ,122.0521438 + ,112.7276133 + ,133.904332 + ,101.2513714 + ,139.0865559 + ,95.38962412 + ,108.8766625 + ,65.91630983 + ,115.1856876 + ,102.6315512 + ,115.6691947 + ,78.02092729 + ,120.9637761 + ,97.4548626 + ,123.9914171 + ,91.22259259 + ,129.36891 + ,104.5786292 + ,116.758687 + ,77.93765181 + ,122.9575427 + ,92.29742609 + ,104.4175501 + ,64.63222588 + ,110.141059 + ,110.9875683 + ,126.0968016 + ,78.3867933 + ,133.176465 + ,105.8021742 + ,116.4153494 + ,84.87462868 + ,121.5219433 + ,111.8918201 + ,124.9633515 + ,89.98870491 + ,130.6031139 + ,103.8228915 + ,115.1008403 + ,73.0215744 + ,121.0710877 + ,88.77039341 + ,98.09674613 + ,47.74551471 + ,106.0371563 + ,99.64603189 + ,120.363441 + ,71.94359107 + ,128.202469 + ,116.3842087 + ,134.640648 + ,92.80437152 + ,141.2859668 + ,105.8843568 + ,120.3960364 + ,73.10718 + ,127.330164 + ,105.6790398 + ,121.4623097 + ,71.52680556 + ,129.1055687 + ,100.0633975 + ,127.512688 + ,82.52353093 + ,134.8829947 + ,111.0560268 + ,121.7025233 + ,79.06391846 + ,128.5084369 + ,98.57552512 + ,105.5323282 + ,59.32467885 + ,112.5699543 + ,115.2147299 + ,125.2278344 + ,70.88654003 + ,133.5641694 + ,111.5409509 + ,119.5097996 + ,77.70378055 + ,126.2937474 + ,113.0410358 + ,122.8595913 + ,77.71239849 + ,130.1841785 + ,103.0732677 + ,117.3303966 + ,64.46101468 + ,125.4617831 + ,94.47214625 + ,109.0071126 + ,53.2335049 + ,117.9590669 + ,104.967443 + ,123.6713015 + ,70.18026775 + ,132.5501127) + ,dim=c(4 + ,80) + ,dimnames=list(c('intermediare' + ,'totaal' + ,'duurzaam' + ,'niet-duurzaam') + ,1:80)) > y <- array(NA,dim=c(4,80),dimnames=list(c('intermediare','totaal','duurzaam','niet-duurzaam'),1:80)) > 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: Wessa P., (2007), Multivariate Correlation Matrix (v1.0.3) in Free Statistics Software (v$_version), Office for Research Development and Education, URL http://www.wessa.net/rwasp_pairs.wasp/ > #Source of accompanying publication: Office for Research, Development, and Education > #Technical description: Write here your technical program description > 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/1z31p1196002552.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 > 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] 4 > cor.test(y[1,],y[2,],method='kendall') Kendall's rank correlation tau data: y[1, ] and y[2, ] z = 5.5259, p-value = 3.278e-08 alternative hypothesis: true tau is not equal to 0 sample estimates: tau 0.4211526 > 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/281ud1196002552.tab") > > system("convert tmp/1z31p1196002552.ps tmp/1z31p1196002552.png") > > > proc.time() user system elapsed 0.822 0.236 0.979