R version 2.12.0 (2010-10-15) Copyright (C) 2010 The R Foundation for Statistical Computing ISBN 3-900051-07-0 Platform: i486-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 <- c(168.67 + ,164.83 + ,184.38 + ,180.81 + ,190.54 + ,181.41 + ,155.67 + ,135.99 + ,125.88 + ,126.09 + ,114.86 + ,127.98 + ,127.98 + ,125.11 + ,125.93 + ,128.2 + ,125.93 + ,111.94 + ,120.01 + ,124.09 + ,126.02 + ,136.41 + ,143.79 + ,141.67 + ,143.9 + ,155 + ,144.83 + ,141.4 + ,137 + ,141.02 + ,131.11 + ,132.83 + ,136.73 + ,141.18 + ,137.86 + ,133.79 + ,128.53 + ,125.87 + ,124.27 + ,123.96 + ,128.15 + ,126.4 + ,127.86 + ,129.31 + ,132.56 + ,141.28 + ,145.55 + ,146.54 + ,143.14 + ,145.72 + ,148.21 + ,150.4 + ,149.94 + ,146.66 + ,143.37 + ,145.29 + ,140.24 + ,136.12 + ,140.25 + ,140.64 + ,145.58 + ,143.73 + ,141.27 + ,140.66 + ,141.94 + ,141.16 + ,134.31 + ,132.93 + ,133.07 + ,140.48 + ,154.85 + ,196.77 + ,235.3 + ,226.52 + ,237.62 + ,224.07 + ,208.74 + ,174.54 + ,170.63 + ,172.23 + ,198.36 + ,175.91 + ,154.63 + ,134.31 + ,121.75 + ,119.6 + ,102.04 + ,106.3 + ,116.38 + ,103.72 + ,98.56 + ,100.9 + ,110 + ,118.26 + ,124.77 + ,125.22 + ,126.38 + ,137.14 + ,134.74 + ,134.3 + ,136.39 + ,141.83 + ,139.24 + ,128.89 + ,134.83 + ,130.43 + ,132.09 + ,144.95 + ,149.5 + ,137.57 + ,139.38 + ,143.06 + ,138.65 + ,123.21 + ,85.91 + ,77.4 + ,77.84 + ,67.76 + ,70.72 + ,72.55 + ,75.83 + ,84.01 + ,93.96 + ,93.73 + ,92.02 + ,88.26 + ,86.48 + ,94.42 + ,94.92 + ,91.41 + ,84.84 + ,89.89 + ,86.32 + ,89.57 + ,93.72 + ,92.27 + ,87.59 + ,85.5 + ,82.81 + ,81.62 + ,87.45 + ,79.86 + ,78.52 + ,75.1 + ,72.99 + ,67.88 + ,70.14 + ,65.43 + ,60.26 + ,58.38 + ,57.68 + ,52.42 + ,52.73 + ,61.4 + ,67.13 + ,77.46 + ,68.66 + ,67.46 + ,62.77 + ,56.88 + ,61.48 + ,61.99 + ,71.56 + ,76.56 + ,79.82 + ,75.05 + ,77.07 + ,80 + ,77.21 + ,82.16 + ,85.57 + ,89.23 + ,121.98 + ,142.56 + ,217.67 + ,198.07 + ,220.1 + ,198.68 + ,181.64 + ,167.47 + ,172.33 + ,168.71 + ,178.22 + ,172.81 + ,168.83 + ,152.25 + ,143.83 + ,151.41 + ,131.87 + ,125.38 + ,123.23 + ,103.99 + ,109.38 + ,123.79 + ,119.05 + ,122.01 + ,128.56 + ,127.91 + ,120.47 + ,122.49 + ,114.05 + ,120.62 + ,119.61 + ,115.01 + ,131.83 + ,167.2 + ,193.82 + ,204.43 + ,264.5 + ,212.55 + ,186.52 + ,185.17 + ,184.38 + ,161.45 + ,154.15 + ,174.25 + ,175.04 + ,175.87 + ,154.82 + ,147.08 + ,134.35 + ,121.56 + ,113.86 + ,119.89 + ,108.07 + ,107.07 + ,115.14 + ,116.03 + ,111.48 + ,103.24 + ,103.23 + ,99.69 + ,108.91 + ,104.21 + ,90.85 + ,87.64 + ,81.06 + ,92.2 + ,114.02 + ,123.56 + ,109.17 + ,101.65 + ,97.95 + ,92.56 + ,91.76 + ,84.1 + ,84.67 + ,74.52 + ,73.83 + ,75.37 + ,70.47 + ,64.5 + ,64.98 + ,66.94 + ,65.93 + ,65.51 + ,68.94 + ,63.67 + ,58.47 + ,59.68 + ,57.71 + ,56.53 + ,58.96 + ,55.6 + ,57.34 + ,60.51 + ,66.38 + ,65.78 + ,58.43 + ,55.16 + ,53.09 + ,52.02 + ,57.58 + ,64.05 + ,70.18 + ,63.86 + ,65.22 + ,67.6 + ,61.66 + ,65.32 + ,66.18 + ,61.34 + ,62.29 + ,63.6 + ,65.51 + ,62.58 + ,62.36 + ,64.88 + ,73.73 + ,77.51 + ,77.47 + ,74.34 + ,75.81 + ,82.16 + ,73.96 + ,73.17 + ,80.99 + ,79.81 + ,89.51 + ,102.57 + ,107.11 + ,122.23 + ,134.69 + ,128.79 + ,126.16 + ,119.98 + ,108.45 + ,108.43 + ,98.17 + ,106.09 + ,108.81 + ,103.03 + ,124.36 + ,118.52 + ,112.2 + ,114.71 + ,107.96 + ,101.21 + ,102.77 + ,112.13 + ,109.36 + ,110.91 + ,123.57 + ,129.95 + ,124.46 + ,122.34 + ,116.61 + ,114.59 + ,112.52 + ,118.67 + ,116.8 + ,123.63 + ,128.04 + ,134.57 + ,130.33 + ,136.47 + ,139.05 + ,158.21 + ,148.07 + ,137.74 + ,139.74 + ,144.08 + ,145.35 + ,145.77 + ,140.56 + ,121.41 + ,120.44 + ,116.97 + ,128.03 + ,128.51 + ,127.76 + ,134.58 + ,147.64 + ,144.46 + ,137.6 + ,146.87 + ,145.67 + ,151.95 + ,150.23 + ,155.86 + ,154.4 + ,156.36 + ,162.13 + ,171.06 + ,174.01 + ,193.52 + ,205.26 + ,212.8 + ,222.1) > par7 = '0.95' > par6 = 'White Noise' > par5 = '12' > par4 = '0' > par3 = '1' > par2 = '1' > par1 = 'Default' > #'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: > 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 (par6 == 'White Noise') par6 <- 'white' else par6 <- 'ma' > par7 <- as.numeric(par7) > 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/rcomp/tmp/1yqc51291715186.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) > racf <- acf(x, par1, main='Autocorrelation', xlab='time lag', ylab='ACF', ci.type=par6, ci=par7, sub=paste('(lambda=',par2,', d=',par3,', D=',par4,', CI=', par7, ', CI type=',par6,')',sep='')) > dev.off() null device 1 > postscript(file="/var/www/rcomp/tmp/2rhtq1291715186.ps",horizontal=F,onefile=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.1735269377 0.1421377033 0.0009388305 -0.0497325039 [6] -0.1819305987 -0.0762369191 0.0058649657 -0.0058030420 0.0524082803 [11] 0.0034047252 0.0351107194 -0.0395757820 -0.0436875952 -0.1016927763 [16] -0.0874080373 -0.0953764526 -0.1544786329 -0.0562970056 0.0182264316 [21] 0.0034699918 0.0645077057 0.0309142360 -0.0066606526 0.0095774713 [26] 0.0095444483 > (mypacf <- c(rpacf$acf)) [1] 0.173526938 0.115504119 -0.042760996 -0.062616690 -0.166874214 [6] -0.010217821 0.069304389 -0.009409186 0.030703879 -0.045075843 [11] 0.017687977 -0.032527515 -0.037537104 -0.074038324 -0.058289357 [16] -0.055255506 -0.138010491 -0.026701620 0.037872048 -0.031693121 [21] 0.034532061 -0.038527320 -0.038502756 0.034012728 0.014534999 > lengthx <- length(x) > sqrtn <- sqrt(lengthx) > > #Note: the /var/www/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab > load(file="/var/www/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 2:(par1+1)) { + 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(abs(mytstat),lengthx),6)) + a<-table.row.end(a) + } > a<-table.end(a) > table.save(a,file="/var/www/rcomp/tmp/3c0aw1291715186.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,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(abs(mytstat),lengthx),6)) + a<-table.row.end(a) + } > a<-table.end(a) > table.save(a,file="/var/www/rcomp/tmp/4f0811291715186.tab") > try(system("convert tmp/1yqc51291715186.ps tmp/1yqc51291715186.png",intern=TRUE)) character(0) > try(system("convert tmp/2rhtq1291715186.ps tmp/2rhtq1291715186.png",intern=TRUE)) character(0) > > > proc.time() user system elapsed 0.600 0.420 1.028