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(0.007850049,0.008671912,0.008391986,0.008691954,0.008724839,0.008949762,0.009344295,0.009971514,0.010388067,0.008884599,0.01000981,0.012393539,0.007933519,0.008087396,0.008120881,0.008147148,0.00917087,0.009668358,0.009897495,0.011217878,0.010190084,0.009560637,0.011200671,0.013546776,0.008524882,0.009142143,0.008793047,0.009296235,0.009974995,0.009692013,0.010120046,0.011004981,0.010328492,0.009428406,0.011114429,0.011798579,0.008997058,0.008803914,0.007974159,0.008460945,0.009917747,0.009604284,0.011028851,0.011162991,0.010420855,0.009897095,0.010715298,0.012461041,0.008754735,0.009381664,0.008843755,0.009235122,0.009973356,0.009146341,0.011038445,0.010830104,0.010585414,0.010560523,0.010897526,0.014012667) > par5 = '12' > par4 = '1' > 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/1yt501197316578.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/2c1df1197316578.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.0000000000 0.3014904929 0.3466389920 0.1687445761 0.1011963575 [6] 0.1100225378 0.0500648429 -0.0657534985 -0.0565927052 -0.0074768197 [11] -0.2448226281 -0.2419119395 -0.3933207093 -0.3120861552 -0.1727712200 [16] -0.0651920206 -0.2623282955 0.0132931177 -0.0553146859 -0.0574083949 [21] 0.0215689011 -0.0645796905 0.0001064336 0.1199086354 0.0055914534 [26] 0.0703151137 0.0692034853 -0.0490517043 -0.0070714115 -0.0485536339 [31] -0.0607045880 0.0305985514 0.0617804358 0.0674926517 0.0314837908 [36] 0.0155650783 -0.0295098375 -0.0076303152 0.0406318265 -0.0025648559 [41] 0.1364794469 0.0569706776 0.0422339350 0.0123290740 -0.0690255797 [46] -0.0352584678 -0.0549027609 -0.0098784897 > (mypacf <- c(rpacf$acf)) [1] 3.014905e-01 2.813128e-01 1.053875e-02 -4.153344e-02 5.397528e-02 [6] -1.854365e-03 -1.419134e-01 -4.275882e-02 8.861007e-02 -2.678439e-01 [11] -2.050480e-01 -2.062823e-01 -6.780602e-02 8.048666e-02 1.580850e-01 [16] -2.482995e-01 1.275218e-01 7.172666e-02 -1.407702e-01 -3.613572e-02 [21] 2.844317e-05 -1.221350e-01 -4.080648e-02 -1.818123e-01 4.793335e-02 [26] 3.514112e-03 -1.091757e-01 -1.338837e-01 -4.248178e-02 3.614917e-02 [31] 8.614421e-02 -9.870901e-02 1.497648e-01 -9.092210e-02 -1.437084e-01 [36] -4.676611e-02 -6.432566e-02 3.760201e-02 -2.020588e-02 -1.099776e-01 [41] 3.951967e-02 -1.945358e-02 -5.798981e-02 -5.736204e-02 2.487075e-02 [46] -7.248956e-02 -6.164843e-03 > 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/3mja31197316578.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/4ialq1197316578.tab") > > system("convert tmp/1yt501197316578.ps tmp/1yt501197316578.png") > system("convert tmp/2c1df1197316578.ps tmp/2c1df1197316578.png") > > > proc.time() user system elapsed 0.863 0.324 0.997