R version 2.15.2 (2012-10-26) -- "Trick or Treat" Copyright (C) 2012 The R Foundation for Statistical Computing ISBN 3-900051-07-0 Platform: i686-pc-linux-gnu (32-bit) 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(210907 + ,56 + ,396 + ,81 + ,120982 + ,56 + ,297 + ,55 + ,176508 + ,54 + ,559 + ,50 + ,179321 + ,89 + ,967 + ,125 + ,123185 + ,40 + ,270 + ,40 + ,52746 + ,25 + ,143 + ,37 + ,385534 + ,92 + ,1562 + ,63 + ,33170 + ,18 + ,109 + ,44 + ,101645 + ,63 + ,371 + ,88 + ,149061 + ,44 + ,656 + ,66 + ,165446 + ,33 + ,511 + ,57 + ,237213 + ,84 + ,655 + ,74 + ,173326 + ,88 + ,465 + ,49 + ,133131 + ,55 + ,525 + ,52 + ,258873 + ,60 + ,885 + ,88 + ,180083 + ,66 + ,497 + ,36 + ,324799 + ,154 + ,1436 + ,108 + ,230964 + ,53 + ,612 + ,43 + ,236785 + ,119 + ,865 + ,75 + ,135473 + ,41 + ,385 + ,32 + ,202925 + ,61 + ,567 + ,44 + ,215147 + ,58 + ,639 + ,85 + ,344297 + ,75 + ,963 + ,86 + ,153935 + ,33 + ,398 + ,56 + ,132943 + ,40 + ,410 + ,50 + ,174724 + ,92 + ,966 + ,135 + ,174415 + ,100 + ,801 + ,63 + ,225548 + ,112 + ,892 + ,81 + ,223632 + ,73 + ,513 + ,52 + ,124817 + ,40 + ,469 + ,44 + ,221698 + ,45 + ,683 + ,113 + ,210767 + ,60 + ,643 + ,39 + ,170266 + ,62 + ,535 + ,73 + ,260561 + ,75 + ,625 + ,48 + ,84853 + ,31 + ,264 + ,33 + ,294424 + ,77 + ,992 + ,59 + ,101011 + ,34 + ,238 + ,41 + ,215641 + ,46 + ,818 + ,69 + ,325107 + ,99 + ,937 + ,64 + ,7176 + ,17 + ,70 + ,1 + ,167542 + ,66 + ,507 + ,59 + ,106408 + ,30 + ,260 + ,32 + ,96560 + ,76 + ,503 + ,129 + ,265769 + ,146 + ,927 + ,37 + ,269651 + ,67 + ,1269 + ,31 + ,149112 + ,56 + ,537 + ,65 + ,175824 + ,107 + ,910 + ,107 + ,152871 + ,58 + ,532 + ,74 + ,111665 + ,34 + ,345 + ,54 + ,116408 + ,61 + ,918 + ,76 + ,362301 + ,119 + ,1635 + ,715 + ,78800 + ,42 + ,330 + ,57 + ,183167 + ,66 + ,557 + ,66 + ,277965 + ,89 + ,1178 + ,106 + ,150629 + ,44 + ,740 + ,54 + ,168809 + ,66 + ,452 + ,32 + ,24188 + ,24 + ,218 + ,20 + ,329267 + ,259 + ,764 + ,71 + ,65029 + ,17 + ,255 + ,21 + ,101097 + ,64 + ,454 + ,70 + ,218946 + ,41 + ,866 + ,112 + ,244052 + ,68 + ,574 + ,66 + ,341570 + ,168 + ,1276 + ,190 + ,103597 + ,43 + ,379 + ,66 + ,233328 + ,132 + ,825 + ,165 + ,256462 + ,105 + ,798 + ,56 + ,206161 + ,71 + ,663 + ,61 + ,311473 + ,112 + ,1069 + ,53 + ,235800 + ,94 + ,921 + ,127 + ,177939 + ,82 + ,858 + ,63 + ,207176 + ,70 + ,711 + ,38 + ,196553 + ,57 + ,503 + ,50 + ,174184 + ,53 + ,382 + ,52 + ,143246 + ,103 + ,464 + ,42 + ,187559 + ,121 + ,717 + ,76 + ,187681 + ,62 + ,690 + ,67 + ,119016 + ,52 + ,462 + ,50 + ,182192 + ,52 + ,657 + ,53 + ,73566 + ,32 + ,385 + ,39 + ,194979 + ,62 + ,577 + ,50 + ,167488 + ,45 + ,619 + ,77 + ,143756 + ,46 + ,479 + ,57 + ,275541 + ,63 + ,817 + ,73 + ,243199 + ,75 + ,752 + ,34 + ,182999 + ,88 + ,430 + ,39 + ,135649 + ,46 + ,451 + ,46 + ,152299 + ,53 + ,537 + ,63 + ,120221 + ,37 + ,519 + ,35 + ,346485 + ,90 + ,1000 + ,106 + ,145790 + ,63 + ,637 + ,43 + ,193339 + ,78 + ,465 + ,47 + ,80953 + ,25 + ,437 + ,31 + ,122774 + ,45 + ,711 + ,162 + ,130585 + ,46 + ,299 + ,57 + ,112611 + ,41 + ,248 + ,36 + ,286468 + ,144 + ,1162 + ,263 + ,241066 + ,82 + ,714 + ,78 + ,148446 + ,91 + ,905 + ,63 + ,204713 + ,71 + ,649 + ,54 + ,182079 + ,63 + ,512 + ,63 + ,140344 + ,53 + ,472 + ,77 + ,220516 + ,62 + ,905 + ,79 + ,243060 + ,63 + ,786 + ,110 + ,162765 + ,32 + ,489 + ,56 + ,182613 + ,39 + ,479 + ,56 + ,232138 + ,62 + ,617 + ,43 + ,265318 + ,117 + ,925 + ,111 + ,85574 + ,34 + ,351 + ,71 + ,310839 + ,92 + ,1144 + ,62 + ,225060 + ,93 + ,669 + ,56 + ,232317 + ,54 + ,707 + ,74 + ,144966 + ,144 + ,458 + ,60 + ,43287 + ,14 + ,214 + ,43 + ,155754 + ,61 + ,599 + ,68 + ,164709 + ,109 + ,572 + ,53 + ,201940 + ,38 + ,897 + ,87 + ,235454 + ,73 + ,819 + ,46 + ,220801 + ,75 + ,720 + ,105 + ,99466 + ,50 + ,273 + ,32 + ,92661 + ,61 + ,508 + ,133 + ,133328 + ,55 + ,506 + ,79 + ,61361 + ,77 + ,451 + ,51 + ,125930 + ,75 + ,699 + ,207 + ,100750 + ,72 + ,407 + ,67 + ,224549 + ,50 + ,465 + ,47 + ,82316 + ,32 + ,245 + ,34 + ,102010 + ,53 + ,370 + ,66 + ,101523 + ,42 + ,316 + ,76 + ,243511 + ,71 + ,603 + ,65 + ,22938 + ,10 + ,154 + ,9 + ,41566 + ,35 + ,229 + ,42 + ,152474 + ,65 + ,577 + ,45 + ,61857 + ,25 + ,192 + ,25 + ,99923 + ,66 + ,617 + ,115 + ,132487 + ,41 + ,411 + ,97 + ,317394 + ,86 + ,975 + ,53 + ,21054 + ,16 + ,146 + ,2 + ,209641 + ,42 + ,705 + ,52 + ,22648 + ,19 + ,184 + ,44 + ,31414 + ,19 + ,200 + ,22 + ,46698 + ,45 + ,274 + ,35 + ,131698 + ,65 + ,502 + ,74 + ,91735 + ,35 + ,382 + ,103 + ,244749 + ,95 + ,964 + ,144 + ,184510 + ,49 + ,537 + ,60 + ,79863 + ,37 + ,438 + ,134 + ,128423 + ,64 + ,369 + ,89 + ,97839 + ,38 + ,417 + ,42 + ,38214 + ,34 + ,276 + ,52 + ,151101 + ,32 + ,514 + ,98 + ,272458 + ,65 + ,822 + ,99 + ,172494 + ,52 + ,389 + ,52 + ,108043 + ,62 + ,466 + ,29 + ,328107 + ,65 + ,1255 + ,125 + ,250579 + ,83 + ,694 + ,106 + ,351067 + ,95 + ,1024 + ,95 + ,158015 + ,29 + ,400 + ,40 + ,98866 + ,18 + ,397 + ,140 + ,85439 + ,33 + ,350 + ,43 + ,229242 + ,247 + ,719 + ,128 + ,351619 + ,139 + ,1277 + ,142 + ,84207 + ,29 + ,356 + ,73 + ,120445 + ,118 + ,457 + ,72 + ,324598 + ,110 + ,1402 + ,128 + ,131069 + ,67 + ,600 + ,61 + ,204271 + ,42 + ,480 + ,73 + ,165543 + ,65 + ,595 + ,148 + ,141722 + ,94 + ,436 + ,64 + ,116048 + ,64 + ,230 + ,45 + ,250047 + ,81 + ,651 + ,58 + ,299775 + ,95 + ,1367 + ,97 + ,195838 + ,67 + ,564 + ,50 + ,173260 + ,63 + ,716 + ,37 + ,254488 + ,83 + ,747 + ,50 + ,104389 + ,45 + ,467 + ,105 + ,136084 + ,30 + ,671 + ,69 + ,199476 + ,70 + ,861 + ,46 + ,92499 + ,32 + ,319 + ,57 + ,224330 + ,83 + ,612 + ,52 + ,135781 + ,31 + ,433 + ,98 + ,74408 + ,67 + ,434 + ,61 + ,81240 + ,66 + ,503 + ,89 + ,14688 + ,10 + ,85 + ,0 + ,181633 + ,70 + ,564 + ,48 + ,271856 + ,103 + ,824 + ,91 + ,7199 + ,5 + ,74 + ,0 + ,46660 + ,20 + ,259 + ,7 + ,17547 + ,5 + ,69 + ,3 + ,133368 + ,36 + ,535 + ,54 + ,95227 + ,34 + ,239 + ,70 + ,152601 + ,48 + ,438 + ,36 + ,98146 + ,40 + ,459 + ,37 + ,79619 + ,43 + ,426 + ,123 + ,59194 + ,31 + ,288 + ,247 + ,139942 + ,42 + ,498 + ,46 + ,118612 + ,46 + ,454 + ,72 + ,72880 + ,33 + ,376 + ,41 + ,65475 + ,18 + ,225 + ,24 + ,99643 + ,55 + ,555 + ,45 + ,71965 + ,35 + ,252 + ,33 + ,77272 + ,59 + ,208 + ,27 + ,49289 + ,19 + ,130 + ,36 + ,135131 + ,66 + ,481 + ,87 + ,108446 + ,60 + ,389 + ,90 + ,89746 + ,36 + ,565 + ,114 + ,44296 + ,25 + ,173 + ,31 + ,77648 + ,47 + ,278 + ,45 + ,181528 + ,54 + ,609 + ,69 + ,134019 + ,53 + ,422 + ,51 + ,124064 + ,40 + ,445 + ,34 + ,92630 + ,40 + ,387 + ,60 + ,121848 + ,39 + ,339 + ,45 + ,52915 + ,14 + ,181 + ,54 + ,81872 + ,45 + ,245 + ,25 + ,58981 + ,36 + ,384 + ,38 + ,53515 + ,28 + ,212 + ,52 + ,60812 + ,44 + ,399 + ,67 + ,56375 + ,30 + ,229 + ,74 + ,65490 + ,22 + ,224 + ,38 + ,80949 + ,17 + ,203 + ,30 + ,76302 + ,31 + ,333 + ,26 + ,104011 + ,55 + ,384 + ,67 + ,98104 + ,54 + ,636 + ,132 + ,67989 + ,21 + ,185 + ,42 + ,30989 + ,14 + ,93 + ,35 + ,135458 + ,81 + ,581 + ,118 + ,73504 + ,35 + ,248 + ,68 + ,63123 + ,43 + ,304 + ,43 + ,61254 + ,46 + ,344 + ,76 + ,74914 + ,30 + ,407 + ,64 + ,31774 + ,23 + ,170 + ,48 + ,81437 + ,38 + ,312 + ,64 + ,87186 + ,54 + ,507 + ,56 + ,50090 + ,20 + ,224 + ,71 + ,65745 + ,53 + ,340 + ,75 + ,56653 + ,45 + ,168 + ,39 + ,158399 + ,39 + ,443 + ,42 + ,46455 + ,20 + ,204 + ,39 + ,73624 + ,24 + ,367 + ,93 + ,38395 + ,31 + ,210 + ,38 + ,91899 + ,35 + ,335 + ,60 + ,139526 + ,151 + ,364 + ,71 + ,52164 + ,52 + ,178 + ,52 + ,51567 + ,30 + ,206 + ,27 + ,70551 + ,31 + ,279 + ,59 + ,84856 + ,29 + ,387 + ,40 + ,102538 + ,57 + ,490 + ,79 + ,86678 + ,40 + ,238 + ,44 + ,85709 + ,44 + ,343 + ,65 + ,34662 + ,25 + ,232 + ,10 + ,150580 + ,77 + ,530 + ,124 + ,99611 + ,35 + ,291 + ,81 + ,19349 + ,11 + ,67 + ,15 + ,99373 + ,63 + ,397 + ,92 + ,86230 + ,44 + ,467 + ,42 + ,30837 + ,19 + ,178 + ,10 + ,31706 + ,13 + ,175 + ,24 + ,89806 + ,42 + ,299 + ,64 + ,62088 + ,38 + ,154 + ,45 + ,40151 + ,29 + ,106 + ,22 + ,27634 + ,20 + ,189 + ,56 + ,76990 + ,27 + ,194 + ,94 + ,37460 + ,20 + ,135 + ,19 + ,54157 + ,19 + ,201 + ,35 + ,49862 + ,37 + ,207 + ,32 + ,84337 + ,26 + ,280 + ,35 + ,64175 + ,42 + ,260 + ,48 + ,59382 + ,49 + ,227 + ,49 + ,119308 + ,30 + ,239 + ,48 + ,76702 + ,49 + ,333 + ,62 + ,103425 + ,67 + ,428 + ,96 + ,70344 + ,28 + ,230 + ,45 + ,43410 + ,19 + ,292 + ,63 + ,104838 + ,49 + ,350 + ,71 + ,62215 + ,27 + ,186 + ,26 + ,69304 + ,30 + ,326 + ,48 + ,53117 + ,22 + ,155 + ,29 + ,19764 + ,12 + ,75 + ,19 + ,86680 + ,31 + ,361 + ,45 + ,84105 + ,20 + ,261 + ,45 + ,77945 + ,20 + ,299 + ,67 + ,89113 + ,39 + ,300 + ,30 + ,91005 + ,29 + ,450 + ,36 + ,40248 + ,16 + ,183 + ,34 + ,64187 + ,27 + ,238 + ,36 + ,50857 + ,21 + ,165 + ,34 + ,56613 + ,19 + ,234 + ,37 + ,62792 + ,35 + ,176 + ,46 + ,72535 + ,14 + ,329 + ,44) + ,dim=c(4 + ,289) + ,dimnames=list(c('time_in_rfc' + ,'logins' + ,'compendium_views_info' + ,'compendium_views_pr') + ,1:289)) > y <- array(NA,dim=c(4,289),dimnames=list(c('time_in_rfc','logins','compendium_views_info','compendium_views_pr'),1:289)) > for (i in 1:dim(x)[1]) + { + for (j in 1:dim(x)[2]) + { + y[i,j] <- as.numeric(x[i,j]) + } + } > par1 = 'pearson' > main = 'Correlation Matrix' > 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', ...) + } > postscript(file="/var/wessaorg/rcomp/tmp/19dbn1354810344.ps",horizontal=F,onefile=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/wessaorg/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab > load(file="/var/wessaorg/rcomp/createtable") > > n <- length(y[,1]) > n [1] 4 > 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="/var/wessaorg/rcomp/tmp/2u3021354810344.tab") > 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) Pearson's product-moment correlation data: y[1, ] and y[2, ] t = 17.3737, df = 287, p-value < 2.2e-16 alternative hypothesis: true correlation is not equal to 0 95 percent confidence interval: 0.6546650 0.7679082 sample estimates: cor 0.7159639 > 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) + } + } Warning messages: 1: In cor.test.default(y[i, ], y[j, ], method = "spearman") : Cannot compute exact p-values with ties 2: In cor.test.default(y[i, ], y[j, ], method = "spearman") : Cannot compute exact p-values with ties 3: In cor.test.default(y[i, ], y[j, ], method = "spearman") : Cannot compute exact p-values with ties 4: In cor.test.default(y[i, ], y[j, ], method = "spearman") : Cannot compute exact p-values with ties 5: In cor.test.default(y[i, ], y[j, ], method = "spearman") : Cannot compute exact p-values with ties 6: In cor.test.default(y[i, ], y[j, ], method = "spearman") : Cannot compute exact p-values with ties > a<-table.end(a) > table.save(a,file="/var/wessaorg/rcomp/tmp/377dr1354810344.tab") > > try(system("convert tmp/19dbn1354810344.ps tmp/19dbn1354810344.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 1.576 0.213 1.767