Home » date » 2007 » Nov » 28 » attachments

workshop 7 Q2 M

R Software Module: rwasp_autocorrelation.wasp (opens new window with default values)
Title produced by software: (Partial) Autocorrelation Function
Date of computation: Wed, 28 Nov 2007 12:47:57 -0700
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2007/Nov/28/t1196278672h4273r55fxg5y30.htm/, Retrieved Wed, 28 Nov 2007 20:37:54 +0100
 
User-defined keywords:
 
Dataseries X:
» Textbox « » Textfile « » CSV «
124,9 132 151,4 108,9 121,3 123,4 90,3 79,3 117,2 116,9 120,8 96,1 100,8 105,3 116,1 112,8 114,5 117,2 77,1 80,1 120,3 133,4 109,4 93,2 91,2 99,2 108,2 101,5 106,9 104,4 77,9 60 99,5 95 105,6 102,5 93,3 97,3 127 111,7 96,4 133 72,2 95,8 124,1 127,6 110,7 104,6 112,7 115,3 139,4 119 97,4 154 81,5 88,8 127,7 105,1 114,9 106,4 104,5 121,6 141,4 99 126,7 134,1 81,3 88,6 132,7 132,9 134,4 103,7 119,7 115 132,9 108,5 113,9 142,9 95,2 93
 
Text written by user:
 
Output produced by software:


Summary of compuational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time1 seconds
R Server'Gwilym Jenkins' @ 72.249.127.135


Autocorrelation Function
Time lag kACF(k)T-STATP-value
018.94430
10.1480891.32460.094546
2-0.128383-1.14830.872865
30.1140371.020.155407
40.0215240.19250.423912
50.0882380.78920.216157
60.1839841.64560.051884
70.0737970.66010.255556
80.0552230.49390.311355
90.056550.50580.307195
10-0.25098-2.24480.98623
110.030050.26880.394396
120.5523384.94032e-06
130.0219240.19610.422517
14-0.211737-1.89380.969069
150.0404270.36160.359305
16-0.084761-0.75810.774698
17-0.028832-0.25790.601421
180.0509350.45560.324963
190.0142960.12790.449286
20-0.038909-0.3480.635626
210.0146390.13090.448076
22-0.279875-2.50330.99283
23-0.010126-0.09060.535968
240.4080973.65010.000233
25-0.042356-0.37880.647096
26-0.17479-1.56340.939043
27-0.049931-0.44660.671812
28-0.126197-1.12870.868809
29-0.076227-0.68180.751331
30-0.054494-0.48740.686348
31-0.125113-1.1190.866764
32-0.112403-1.00540.841123
33-0.05747-0.5140.695674
34-0.221581-1.98190.974536
35-0.061213-0.54750.707223


Partial Autocorrelation Function
Time lag kPACF(k)T-STATP-value
00.1480891.32460.094546
1-0.153684-1.37460.913452
20.1662151.48670.070517
3-0.052621-0.47070.680415
40.1470141.31490.096144
50.1259821.12680.131595
60.0623110.55730.289431
70.0636240.56910.285452
80.018360.16420.434987
9-0.299026-2.67460.995465
100.1162981.04020.15069
110.4765064.2622.7e-05
12-0.146687-1.3120.903365
13-0.194-1.73520.956721
140.0249490.22320.411992
15-0.067873-0.60710.72724
16-0.053422-0.47780.682959
17-0.082429-0.73730.768442
180.0637040.56980.285211
19-0.155449-1.39040.915866
200.089020.79620.214129
21-0.045898-0.41050.658741
220.0809210.72380.235656
230.0802740.7180.237427
24-0.035529-0.31780.624259
25-0.003762-0.03360.513378
26-0.158197-1.4150.91952
27-0.021364-0.19110.575528
28-0.037621-0.33650.63131
29-0.171574-1.53460.935587
30-0.162001-1.4490.924374
31-0.100518-0.89910.81434
320.0273080.24430.40383
330.0874470.78220.218216
34-0.008849-0.07910.531443
35-0.024779-0.22160.587417
 
Charts produced by software:
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2007/Nov/28/t1196278672h4273r55fxg5y30/1rjiw1196279274.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2007/Nov/28/t1196278672h4273r55fxg5y30/1rjiw1196279274.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2007/Nov/28/t1196278672h4273r55fxg5y30/2l5jg1196279274.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2007/Nov/28/t1196278672h4273r55fxg5y30/2l5jg1196279274.ps (open in new window)


 
Parameters:
par1 = 36 ; par2 = 1 ; par3 = 1 ; par4 = 1 ; par5 = 12 ;
 
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 (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)
bitmap(file='pic1.png')
racf <- acf(x,par1,main='Autocorrelation',xlab='lags',ylab='ACF')
dev.off()
bitmap(file='pic2.png')
rpacf <- pacf(x,par1,main='Partial Autocorrelation',xlab='lags',ylab='PACF')
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 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='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-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='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:

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