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. > y <- c(2.3,2.4,2.3,2.1,3,2.6,2.2,2.3,2.6,3.1,2.7,2.6,3,3,3.2,3.3,2.5,2.6,3.1,3.1,3.1,2.5,2.9,3.1,2.8,2.7,2.6,2.2,2,2.3,2.4,2,2.1,2.1,2.1,1.6,1.6,1.6,1.5,1.7,2.5,3.2,3.4,3.8,3.9,4.7,4.4,5.4,6.1,6.2,5.7,5.8,5.1,3.5,3,2.4,2.2,0.9,1,0.1) > x <- c(130.7,117.2,110.8,111.4,108.2,108.8,110.2,109.5,109.5,116,111.2,112.1,114,119.1,114.1,115.1,115.4,110.8,116,119.2,126.5,127.8,131.3,140.3,137.3,143,134.5,139.9,159.3,170.4,175,175.8,180.9,180.3,169.6,172.3,184.8,177.7,184.6,211.4,215.3,215.9,244.7,259.3,289,310.9,321,315.1,333.2,314.1,284.7,273.9,216,196.4,190.9,206.4,196.3,199.5,198.9,214.4) > ylab = 'Consumptieprijsindex' > xlab = 'Prijsindex graan' > #'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: > k <- cor.test(x,y,method='spearman') Warning message: In cor.test.default(x, y, method = "spearman") : Cannot compute exact p-values with ties > postscript(file="/var/www/html/rcomp/tmp/1dbbj1260705072.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(x,y,main='Scatterplot',xlab=xlab,ylab=ylab) > grid() > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/24r3q1260705072.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot(rank(x),rank(y),main='Scatterplot of Ranks',xlab=xlab,ylab=ylab) > grid() > 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,'Spearman Rank Correlation',2,TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'rho',header=TRUE) > a<-table.element(a,k$estimate) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'2-sided p-value',header=TRUE) > a<-table.element(a,k$p.value) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'S',header=TRUE) > a<-table.element(a,k$statistic) > a<-table.row.end(a) > a<-table.end(a) > table.save(a,file="/var/www/html/rcomp/tmp/3ndby1260705072.tab") > > try(system("convert tmp/1dbbj1260705072.ps tmp/1dbbj1260705072.png",intern=TRUE)) character(0) > try(system("convert tmp/24r3q1260705072.ps tmp/24r3q1260705072.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 0.539 0.333 0.628