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 <- c(4.68,4.68,4.67,4.58,4.48,4.46,4.46,4.46,4.45,4.45,4.45,4.45,4.45,4.45,4.45,4.45,4.44,4.44,4.44,4.44,4.44,4.43,4.38,4.23,4.2,4.2,4.2,4.2,4.2,4.19,4.16,4.06,4,3.99,3.95,3.81,3.8,3.8,3.8,3.8,3.79,3.79,3.78,3.69,3.69,3.69,3.69,3.69,3.69,3.69,3.69,3.68,3.63,3.61,3.61,3.61,3.6,3.58,3.52,3.52,3.52,3.52,3.52,3.52,3.52,3.52,3.52,3.51,3.47,3.43,3.42,3.42,3.42,3.42,3.42,3.42,3.42,3.42,3.42,3.42,3.42) > par5 = '12' > par4 = '0' > par3 = '0' > par2 = '1' > par1 = '48' > #'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!) > if (par1 == 'Default') { + par1 = 10*log10(length(x)) + } else { + par1 <- as.numeric(par1) + } > par2 <- as.numeric(par2) > par3 <- as.numeric(par3) > par4 <- as.numeric(par4) > par5 <- as.numeric(par5) > if (par2 == 0) { + x <- log(x) + } else { + x <- (x ^ par2 - 1) / par2 + } > if (par3 > 0) x <- diff(x,lag=1,difference=par3) > if (par4 > 0) x <- diff(x,lag=par5,difference=par4) > postscript(file="/var/www/html/rcomp/tmp/1e2741196274385.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > racf <- acf(x,par1,main='Autocorrelation',xlab='lags',ylab='ACF') > dev.off() null device 1 > postscript(file="/var/www/html/rcomp/tmp/2v08h1196274385.ps",horizontal=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > rpacf <- pacf(x,par1,main='Partial Autocorrelation',xlab='lags',ylab='PACF') > dev.off() null device 1 > (myacf <- c(racf$acf)) [1] 1.00000000 0.96703589 0.93066446 0.89373054 0.86056911 0.83153529 [7] 0.80282764 0.77352246 0.74332099 0.71129084 0.67751791 0.64279179 [13] 0.60688537 0.56984290 0.53319379 0.49648117 0.45908568 0.42173945 [19] 0.38339734 0.34388152 0.30238105 0.25836244 0.21367465 0.17105422 [25] 0.13786143 0.10663141 0.07517429 0.04255769 0.00818407 -0.02697808 [31] -0.06108534 -0.09421200 -0.12332486 -0.15036376 -0.17763081 -0.20365513 [37] -0.22320651 -0.24285089 -0.26311413 -0.28079758 -0.29901401 -0.31733055 [43] -0.33537626 -0.35292455 -0.36564047 -0.37858402 -0.39173333 -0.40050762 [49] -0.40827682 > (mypacf <- c(rpacf$acf)) [1] 0.967035893 -0.069306694 -0.024924533 0.039720684 0.040380006 [6] -0.018130611 -0.023673941 -0.023161159 -0.040886308 -0.043766157 [11] -0.033807118 -0.041430369 -0.043718752 -0.019809153 -0.028503143 [16] -0.039027706 -0.024646927 -0.040208386 -0.045144316 -0.058987802 [21] -0.069124699 -0.045412371 -0.008597957 0.103842770 -0.015536384 [26] -0.034033245 -0.026773891 -0.035874151 -0.038542551 -0.016521118 [31] -0.023741661 0.019557050 -0.009509521 -0.040237597 -0.011427777 [36] 0.075904341 -0.033178919 -0.040674001 0.022289297 -0.031213814 [41] -0.042322875 -0.032928665 -0.033042247 0.025092171 -0.050035077 [46] -0.032439819 0.061526875 -0.011079324 > lengthx <- length(x) > sqrtn <- sqrt(lengthx) > load(file='/var/www/html/rcomp/createtable') > a<-table.start() > a<-table.row.start(a) > a<-table.element(a,'Autocorrelation Function',4,TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Time lag k',header=TRUE) > a<-table.element(a,hyperlink('http://www.xycoon.com/basics.htm','ACF(k)','click here for more information about the Autocorrelation Function'),header=TRUE) > a<-table.element(a,'T-STAT',header=TRUE) > a<-table.element(a,'P-value',header=TRUE) > a<-table.row.end(a) > for (i in 1:par1) { + a<-table.row.start(a) + a<-table.element(a,i-1,header=TRUE) + a<-table.element(a,round(myacf[i],6)) + mytstat <- myacf[i]*sqrtn + a<-table.element(a,round(mytstat,4)) + a<-table.element(a,round(1-pt(mytstat,lengthx),6)) + a<-table.row.end(a) + } > a<-table.end(a) > table.save(a,file="/var/www/html/rcomp/tmp/3cqvt1196274385.tab") > a<-table.start() > a<-table.row.start(a) > a<-table.element(a,'Partial Autocorrelation Function',4,TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Time lag k',header=TRUE) > a<-table.element(a,hyperlink('http://www.xycoon.com/basics.htm','PACF(k)','click here for more information about the Partial Autocorrelation Function'),header=TRUE) > a<-table.element(a,'T-STAT',header=TRUE) > a<-table.element(a,'P-value',header=TRUE) > a<-table.row.end(a) > for (i in 1:par1) { + a<-table.row.start(a) + a<-table.element(a,i-1,header=TRUE) + a<-table.element(a,round(mypacf[i],6)) + mytstat <- mypacf[i]*sqrtn + a<-table.element(a,round(mytstat,4)) + a<-table.element(a,round(1-pt(mytstat,lengthx),6)) + a<-table.row.end(a) + } > a<-table.end(a) > table.save(a,file="/var/www/html/rcomp/tmp/47cmu1196274385.tab") > > system("convert tmp/1e2741196274385.ps tmp/1e2741196274385.png") > system("convert tmp/2v08h1196274385.ps tmp/2v08h1196274385.png") > > > proc.time() user system elapsed 0.863 0.328 0.975