R version 2.6.1 (2007-11-26) 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 <- c(1.74138367229942 + ,-2.88580372001652 + ,-3.00801521083293 + ,5.35873352650856 + ,-0.350197418097050 + ,-4.44477983570422 + ,-14.1704246279256 + ,5.06291770302617 + ,8.16317098727172 + ,-6.63032011800066 + ,-0.955084752066612 + ,4.76580237731785 + ,4.64634662056524 + ,-3.37632197945722 + ,-3.48596660066835 + ,0.00318885841739619 + ,-2.30873579009489 + ,4.510676743397 + ,3.86380235714235 + ,-4.84743390386536 + ,1.19326683102373 + ,9.49359417425812 + ,-5.7256091522179 + ,-6.7409221436693 + ,-8.37465970382766 + ,2.41947579953488 + ,2.51107146040831 + ,2.31318281556092 + ,-3.02118693681124 + ,3.49111382410466 + ,-5.27208657466297 + ,-1.65652539783093 + ,1.158900365591 + ,3.29699796504326 + ,5.45943755223924 + ,-3.39089745529757 + ,-3.24888068501405 + ,-3.76725354399628 + ,-1.01610429731824 + ,-0.141686930225946 + ,-2.40143497370904 + ,3.01483128334767 + ,-2.37153731174333 + ,1.90350531137286 + ,-3.75249259201867 + ,-1.15949421149824 + ,1.41625767699710 + ,0.756276066572336 + ,1.74232125798030 + ,-2.82713799160403 + ,2.91169906841461 + ,-7.53666538846806 + ,8.89398251304836 + ,-1.48741996092416 + ,3.26139630257603 + ,-3.15021888842772 + ,3.8905793816289 + ,7.41906373843078 + ,7.78286136215999 + ,-3.77518512848798 + ,0.0882557144562938 + ,1.75385231671455 + ,1.56061031268522 + ,-1.4983198165646 + ,4.36211820238709 + ,2.31013654316626 + ,-2.33448411305145 + ,-1.40752353154939) > #'GNU S' R Code compiled by R2WASP v. 1.0.44 () > #Author: Prof. Dr. P. Wessa > #To cite this work: Wessa P., (2007), Tukey lambda PPCC Plot (v1.0.1) in Free Statistics Software (v$_version), Office for Research Development and Education, URL http://www.wessa.net/rwasp_tukeylambda.wasp/ > #Source of accompanying publication: Office for Research, Development, and Education > #Technical description: Write here your technical program description > gp <- function(lambda, p) + { + (p^lambda-(1-p)^lambda)/lambda + } > sortx <- sort(x) > c <- array(NA,dim=c(201)) > for (i in 1:201) + { + if (i != 101) c[i] <- cor(gp(ppoints(x), lambda=(i-101)/100),sortx) + } > postscript(file="/var/www/html/rcomp/tmp/15kyq1198008662.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > plot((-100:100)/100,c[1:201],xlab='lambda',ylab='correlation',main='PPCC Plot - Tukey lambda') > grid() > dev.off() null device 1 > load(file='/var/www/html/rcomp/createtable') > a<-table.start() > a<-table.row.start(a) > a<-table.element(a,'Tukey Lambda - Key Values',2,TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Distribution (lambda)',1,TRUE) > a<-table.element(a,'Correlation',1,TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Approx. Cauchy (lambda=-1)',header=TRUE) > a<-table.element(a,c[1]) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Exact Logistic (lambda=0)',header=TRUE) > a<-table.element(a,(c[100]+c[102])/2) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Approx. Normal (lambda=0.14)',header=TRUE) > a<-table.element(a,c[115]) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'U-shaped (lambda=0.5)',header=TRUE) > a<-table.element(a,c[151]) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Exactly Uniform (lambda=1)',header=TRUE) > a<-table.element(a,c[201]) > a<-table.row.end(a) > a<-table.end(a) > table.save(a,file="/var/www/html/rcomp/tmp/2jndt1198008663.tab") > > system("convert tmp/15kyq1198008662.ps tmp/15kyq1198008662.png") > > > proc.time() user system elapsed 1.229 0.303 1.287