Home » date » 2011 » Jan » 16 »

*Unverified author*
R Software Module: /rwasp_autocorrelation.wasp (opens new window with default values)
Title produced by software: (Partial) Autocorrelation Function
Date of computation: Sun, 16 Jan 2011 12:32:26 +0000
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2011/Jan/16/t1295181040oro5ljczcav4qay.htm/, Retrieved Sun, 16 Jan 2011 13:30:43 +0100
 
BibTeX entries for LaTeX users:
@Manual{KEY,
    author = {{YOUR NAME}},
    publisher = {Office for Research Development and Education},
    title = {Statistical Computations at FreeStatistics.org, URL http://www.freestatistics.org/blog/date/2011/Jan/16/t1295181040oro5ljczcav4qay.htm/},
    year = {2011},
}
@Manual{R,
    title = {R: A Language and Environment for Statistical Computing},
    author = {{R Development Core Team}},
    organization = {R Foundation for Statistical Computing},
    address = {Vienna, Austria},
    year = {2011},
    note = {{ISBN} 3-900051-07-0},
    url = {http://www.R-project.org},
}
 
Original text written by user:
 
IsPrivate?
No (this computation is public)
 
User-defined keywords:
KDGP2W12
 
Dataseries X:
» Textbox « » Textfile « » CSV «
10574 10653 10805 10872 10625 10407 10463 10556 10646 10702 11353 11346 11451 11964 12574 13031 13812 14544 14931 14886 16005 17064 15168 16050 15839 15137 14954 15648 15305 15579 16348 15928 16171 15937 15713 15594 15683 16438 17032 17696 17745 19394 20148 20108 18584 18441 18391 19178 18073 18483 19644 19195 19650 20830 23595 22937 21814 21928 21777 21383 21467 22052 22680 24320 24977 25204 27390 26434 27525 30695 32436 30160 30236
 
Output produced by software:


Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time1 seconds
R Server'Gwilym Jenkins' @ www.wessa.org


Autocorrelation Function
Time lag kACF(k)T-STATP-value
10.0316890.26890.394392
2-0.215919-1.83210.035533
30.0838320.71130.239587
40.1408571.19520.117963
5-0.178329-1.51320.067307
6-0.077646-0.65890.256046
70.0007350.00620.497519
8-0.094618-0.80290.212348
90.0052620.04460.482255
10-0.147738-1.25360.107021
110.0425110.36070.359685
120.160871.3650.088248
13-0.007047-0.05980.476243
14-0.081043-0.68770.246933
150.101670.86270.195584
160.1914341.62440.054333
17-0.13216-1.12140.132919
18-0.155043-1.31560.096244
19-0.049745-0.42210.337106
200.0546590.46380.322096
21-0.073431-0.62310.267598
220.0381080.32340.373682
230.1112930.94440.174073
240.0120530.10230.459413
25-0.059318-0.50330.308134
26-0.01888-0.16020.436585
270.1572731.33450.093122
28-0.005978-0.05070.479841
29-0.006004-0.05090.479756
30-0.082831-0.70280.242209
310.0353330.29980.382592
32-0.085113-0.72220.236252
330.0602360.51110.305414
340.0227060.19270.423882
35-0.120197-1.01990.155594
360.0111720.09480.462369
370.0227250.19280.423817
38-0.058823-0.49910.309605
390.0154620.13120.447993
400.0432730.36720.357281
41-0.108088-0.91720.18106
42-0.013893-0.11790.453243
430.0525170.44560.328604
44-0.145327-1.23310.110767
450.0372890.31640.376306
460.0397660.33740.368388
47-0.063534-0.53910.295739
48-0.017412-0.14770.44148


Partial Autocorrelation Function
Time lag kPACF(k)T-STATP-value
10.0316890.26890.394392
2-0.217141-1.84250.034759
30.1040460.88290.190125
40.0899350.76310.223943
5-0.160953-1.36570.088137
6-0.020815-0.17660.43015
7-0.086101-0.73060.233701
8-0.106896-0.9070.183706
90.0530650.45030.326933
10-0.227099-1.9270.028963
110.0965560.81930.207658
120.1012560.85920.196545
13-0.043896-0.37250.355319
140.0242690.20590.418714
15-0.002302-0.01950.492235
160.1560771.32440.094786
17-0.085194-0.72290.236044
18-0.145736-1.23660.110125
19-0.085676-0.7270.234795
20-0.003796-0.03220.487196
210.0017660.0150.494043
220.1291321.09570.138427
230.0619340.52550.300416
240.009520.08080.46792
25-0.048751-0.41370.340173
26-0.050484-0.42840.33483
270.097980.83140.204251
28-0.066935-0.5680.285915
290.0910080.77220.221253
30-0.057289-0.48610.314181
310.0165750.14060.444272
32-0.090741-0.770.221921
330.1663931.41190.081144
340.0254690.21610.414756
35-0.138827-1.1780.12134
36-0.003351-0.02840.488699
37-0.062938-0.5340.297479
38-0.110906-0.94110.174907
390.083220.70610.241188
40-0.04558-0.38680.350038
410.0177320.15050.440412
42-0.017202-0.1460.44218
43-0.099386-0.84330.200922
44-0.110322-0.93610.176171
450.0002260.00190.499237
46-0.005111-0.04340.482766
47-0.000959-0.00810.496766
480.0005160.00440.498261
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2011/Jan/16/t1295181040oro5ljczcav4qay/16twh1295181145.png (open in new window)
http://www.freestatistics.org/blog/date/2011/Jan/16/t1295181040oro5ljczcav4qay/16twh1295181145.ps (open in new window)


http://www.freestatistics.org/blog/date/2011/Jan/16/t1295181040oro5ljczcav4qay/2n8nh1295181145.png (open in new window)
http://www.freestatistics.org/blog/date/2011/Jan/16/t1295181040oro5ljczcav4qay/2n8nh1295181145.ps (open in new window)


http://www.freestatistics.org/blog/date/2011/Jan/16/t1295181040oro5ljczcav4qay/3lgbl1295181145.png (open in new window)
http://www.freestatistics.org/blog/date/2011/Jan/16/t1295181040oro5ljczcav4qay/3lgbl1295181145.ps (open in new window)


 
Parameters (Session):
par1 = 48 ; par2 = 1 ; par3 = 1 ; par4 = 0 ; par5 = 12 ; par6 = White Noise ; par7 = 0.95 ;
 
Parameters (R input):
par1 = 48 ; par2 = 1 ; par3 = 1 ; par4 = 0 ; par5 = 12 ; par6 = White Noise ; par7 = 0.95 ;
 
R code (references can be found in the software module):
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 (par8 != '') par8 <- as.numeric(par8)
ox <- x
if (par8 == '') {
if (par2 == 0) {
x <- log(x)
} else {
x <- (x ^ par2 - 1) / par2
}
} else {
x <- log(x,base=par8)
}
if (par3 > 0) x <- diff(x,lag=1,difference=par3)
if (par4 > 0) x <- diff(x,lag=par5,difference=par4)
bitmap(file='picts.png')
op <- par(mfrow=c(2,1))
plot(ox,type='l',main='Original Time Series',xlab='time',ylab='value')
if (par8=='') {
mytitle <- paste('Working Time Series (lambda=',par2,', d=',par3,', D=',par4,')',sep='')
mysub <- paste('(lambda=',par2,', d=',par3,', D=',par4,', CI=', par7, ', CI type=',par6,')',sep='')
} else {
mytitle <- paste('Working Time Series (base=',par8,', d=',par3,', D=',par4,')',sep='')
mysub <- paste('(base=',par8,', d=',par3,', D=',par4,', CI=', par7, ', CI type=',par6,')',sep='')
}
plot(x,type='l', main=mytitle,xlab='time',ylab='value')
par(op)
dev.off()
bitmap(file='pic1.png')
racf <- acf(x, par1, main='Autocorrelation', xlab='time lag', ylab='ACF', ci.type=par6, ci=par7, sub=mysub)
dev.off()
bitmap(file='pic2.png')
rpacf <- pacf(x,par1,main='Partial Autocorrelation',xlab='lags',ylab='PACF',sub=mysub)
dev.off()
(myacf <- c(racf$acf))
(mypacf <- c(rpacf$acf))
lengthx <- length(x)
sqrtn <- sqrt(lengthx)
load(file='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='mytable.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='mytable1.tab')
 





Copyright

Creative Commons License

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 License.

Software written by Ed van Stee & Patrick Wessa


Disclaimer

Information provided on this web site is provided "AS IS" without warranty of any kind, either express or implied, including, without limitation, warranties of merchantability, fitness for a particular purpose, and noninfringement. We use reasonable efforts to include accurate and timely information and periodically update the information, and software without notice. However, we make no warranties or representations as to the accuracy or completeness of such information (or software), and we assume no liability or responsibility for errors or omissions in the content of this web site, or any software bugs in online applications. Your use of this web site is AT YOUR OWN RISK. Under no circumstances and under no legal theory shall we be liable to you or any other person for any direct, indirect, special, incidental, exemplary, or consequential damages arising from your access to, or use of, this web site.


Privacy Policy

We may request personal information to be submitted to our servers in order to be able to:

  • personalize online software applications according to your needs
  • enforce strict security rules with respect to the data that you upload (e.g. statistical data)
  • manage user sessions of online applications
  • alert you about important changes or upgrades in resources or applications

We NEVER allow other companies to directly offer registered users information about their products and services. Banner references and hyperlinks of third parties NEVER contain any personal data of the visitor.

We do NOT sell, nor transmit by any means, personal information, nor statistical data series uploaded by you to third parties.

We carefully protect your data from loss, misuse, alteration, and destruction. However, at any time, and under any circumstance you are solely responsible for managing your passwords, and keeping them secret.

We store a unique ANONYMOUS USER ID in the form of a small 'Cookie' on your computer. This allows us to track your progress when using this website which is necessary to create state-dependent features. The cookie is used for NO OTHER PURPOSE. At any time you may opt to disallow cookies from this website - this will not affect other features of this website.

We examine cookies that are used by third-parties (banner and online ads) very closely: abuse from third-parties automatically results in termination of the advertising contract without refund. We have very good reason to believe that the cookies that are produced by third parties (banner ads) do NOT cause any privacy or security risk.

FreeStatistics.org is safe. There is no need to download any software to use the applications and services contained in this website. Hence, your system's security is not compromised by their use, and your personal data - other than data you submit in the account application form, and the user-agent information that is transmitted by your browser - is never transmitted to our servers.

As a general rule, we do not log on-line behavior of individuals (other than normal logging of webserver 'hits'). However, in cases of abuse, hacking, unauthorized access, Denial of Service attacks, illegal copying, hotlinking, non-compliance with international webstandards (such as robots.txt), or any other harmful behavior, our system engineers are empowered to log, track, identify, publish, and ban misbehaving individuals - even if this leads to ban entire blocks of IP addresses, or disclosing user's identity.


FreeStatistics.org is powered by