Home » date » 2009 » Dec » 04 »

ws9 forcasting 2

*The author of this computation has been verified*
R Software Module: /rwasp_decomposeloess.wasp (opens new window with default values)
Title produced by software: Decomposition by Loess
Date of computation: Fri, 04 Dec 2009 13:37:34 -0700
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2009/Dec/04/t1259959092u5j9mitohjtlctt.htm/, Retrieved Fri, 04 Dec 2009 21:38:18 +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/2009/Dec/04/t1259959092u5j9mitohjtlctt.htm/},
    year = {2009},
}
@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 = {2009},
    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:
 
Dataseries X:
» Textbox « » Textfile « » CSV «
2.05 2.11 2.09 2.05 2.08 2.06 2.06 2.08 2.07 2.06 2.07 2.06 2.09 2.07 2.09 2.28 2.33 2.35 2.52 2.63 2.58 2.70 2.81 2.97 3.04 3.28 3.33 3.50 3.56 3.57 3.69 3.82 3.79 3.96 4.06 4.05 4.03 3.94 4.02 3.88 4.02 4.03 4.09 3.99 4.01 4.01 4.19 4.30 4.27 3.82 3.15 2.49 1.81 1.26 1.06 0.84 0.78 0.70 0.36 0.35
 
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' @ 72.249.127.135


Seasonal Decomposition by Loess - Parameters
ComponentWindowDegreeJump
Seasonal601061
Trend1912
Low-pass1312


Seasonal Decomposition by Loess - Time Series Components
tObservedFittedSeasonalTrendRemainder
12.051.882302168203020.1693670439856082.04833078781137-0.167697831796979
22.112.02929808053920.1363219782190992.0543799412417-0.0807019194607996
32.092.072293936673690.0472769686542832.06042909467203-0.0177060633263122
42.052.06353807359849-0.0275412353919772.064003161793490.0135380735984914
52.082.17878223404962-0.0863594629645642.067577228914940.0987822340496223
62.062.22237466109754-0.1728276291202622.070452968022720.162374661097538
72.062.16996712996999-0.1232958371005012.073328707130510.109967129969994
82.082.18663791610629-0.1036553025822792.077017386475990.106637916106287
92.072.15730878327765-0.09801484909912382.080706065821480.0873087832776474
102.062.03689176925960-0.0009940516845495882.08410228242495-0.0231082307404038
112.071.98447468858370.06802681238786882.08749849902843-0.085525311416299
122.061.817586028041810.1916954892165162.11071848274168-0.242413971958192
132.091.876694489559470.1693670439856082.13393846645492-0.213305510440529
142.071.823862329803480.1363219782190992.17981569197742-0.246137670196518
152.091.907030113845800.0472769686542832.22569291749991-0.182969886154197
162.282.29743114416309-0.0275412353919772.290110091228880.0174311441630932
172.332.39183219800671-0.0863594629645642.354527264957850.0618321980067105
182.352.44042931957099-0.1728276291202622.432398309549270.090429319570994
192.522.65302648295982-0.1232958371005012.510269354140680.133026482959818
202.632.76616124041895-0.1036553025822792.597494062163330.136161240418947
212.582.57329607891314-0.09801484909912382.68471877018598-0.00670392108685558
222.72.62223409308283-0.0009940516845495882.77875995860172-0.0777659069171719
232.812.679172040594670.06802681238786882.87280114701746-0.130827959405332
242.972.774863218028080.1916954892165162.97344129275541-0.195136781971924
253.042.836551517521040.1693670439856083.07408143849335-0.203448482478962
263.283.242104102134610.1363219782190993.18157391964629-0.0378958978653858
273.333.32365663054650.0472769686542833.28906640079922-0.00634336945350089
283.53.62979853927993-0.0275412353919773.397742696112050.129798539279931
293.563.69994047153969-0.0863594629645643.506418991424880.139940471539689
303.573.71472123040134-0.1728276291202623.598106398718930.144721230401335
313.693.81350203108752-0.1232958371005013.689793806012980.123502031087523
323.823.99253394486455-0.1036553025822793.751121357717720.172533944864555
333.793.86556593967665-0.09801484909912383.812448909422470.0755659396766535
343.964.07119904804452-0.0009940516845495883.849795003640030.111199048044517
354.064.164832089754540.06802681238786883.887141097857600.104832089754536
364.053.992644171501280.1916954892165163.91566033928221-0.0573558284987241
374.033.946453375307570.1693670439856083.94417958070682-0.083546624692429
383.943.777258588885770.1363219782190993.96641943289513-0.162741411114235
394.024.004063746262270.0472769686542833.98865928508345-0.0159362537377317
403.883.78091568630651-0.0275412353919774.00662554908547-0.0990843136934925
414.024.10176764987707-0.0863594629645644.024591813087490.0817676498770732
424.034.193663152456-0.1728276291202624.039164476664260.163663152456001
434.094.24955869685947-0.1232958371005014.053737140241030.159558696859470
443.994.05157877486577-0.1036553025822794.032076527716510.0615787748657688
454.014.10759893390713-0.09801484909912384.010415915191990.0975989339071335
464.014.11991747836723-0.0009940516845495883.901076573317320.109917478367232
474.194.520235956169490.06802681238786883.791737231442640.330235956169487
484.34.824613831459110.1916954892165163.583690679324380.524613831459107
494.274.994988828808280.1693670439856083.375644127206110.724988828808282
503.824.402422206563460.1363219782190993.101255815217440.58242220656346
513.153.425855528116950.0472769686542832.826867503228770.275855528116947
522.492.50374077518465-0.0275412353919772.503800460207330.0137407751846479
531.811.52562604577867-0.0863594629645642.18073341718589-0.284373954221325
541.260.837658168057849-0.1728276291202621.85516946106241-0.422341831942151
551.060.713690332161563-0.1232958371005011.52960550493894-0.346309667838437
560.840.58472405964089-0.1036553025822791.19893124294139-0.255275940359110
570.780.789757868155284-0.09801484909912380.868256980943840.00975786815528412
580.70.8627606176834-0.0009940516845495880.538233434001150.1627606176834
590.360.4437633005536720.06802681238786880.2082098870584590.0837633005536717
600.350.6271441023589340.191695489216516-0.1188395915754500.277144102358934
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2009/Dec/04/t1259959092u5j9mitohjtlctt/118nf1259959051.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/04/t1259959092u5j9mitohjtlctt/118nf1259959051.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/04/t1259959092u5j9mitohjtlctt/2ssjt1259959051.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/04/t1259959092u5j9mitohjtlctt/2ssjt1259959051.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/04/t1259959092u5j9mitohjtlctt/3e0wd1259959051.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/04/t1259959092u5j9mitohjtlctt/3e0wd1259959051.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/04/t1259959092u5j9mitohjtlctt/4vclr1259959052.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/04/t1259959092u5j9mitohjtlctt/4vclr1259959052.ps (open in new window)


 
Parameters (Session):
par1 = 60 ; par2 = 1.7 ; par3 = 2 ; par4 = 0 ; par5 = 12 ; par6 = MA ; par7 = 0.95 ;
 
Parameters (R input):
par1 = 12 ; par2 = periodic ; par3 = 0 ; par5 = 1 ; par7 = 1 ; par8 = FALSE ;
 
R code (references can be found in the software module):
par1 <- as.numeric(par1) #seasonal period
if (par2 != 'periodic') par2 <- as.numeric(par2) #s.window
par3 <- as.numeric(par3) #s.degree
if (par4 == '') par4 <- NULL else par4 <- as.numeric(par4)#t.window
par5 <- as.numeric(par5)#t.degree
if (par6 != '') par6 <- as.numeric(par6)#l.window
par7 <- as.numeric(par7)#l.degree
if (par8 == 'FALSE') par8 <- FALSE else par9 <- TRUE #robust
nx <- length(x)
x <- ts(x,frequency=par1)
if (par6 != '') {
m <- stl(x,s.window=par2, s.degree=par3, t.window=par4, t.degre=par5, l.window=par6, l.degree=par7, robust=par8)
} else {
m <- stl(x,s.window=par2, s.degree=par3, t.window=par4, t.degre=par5, l.degree=par7, robust=par8)
}
m$time.series
m$win
m$deg
m$jump
m$inner
m$outer
bitmap(file='test1.png')
plot(m,main=main)
dev.off()
mylagmax <- nx/2
bitmap(file='test2.png')
op <- par(mfrow = c(2,2))
acf(as.numeric(x),lag.max = mylagmax,main='Observed')
acf(as.numeric(m$time.series[,'trend']),na.action=na.pass,lag.max = mylagmax,main='Trend')
acf(as.numeric(m$time.series[,'seasonal']),na.action=na.pass,lag.max = mylagmax,main='Seasonal')
acf(as.numeric(m$time.series[,'remainder']),na.action=na.pass,lag.max = mylagmax,main='Remainder')
par(op)
dev.off()
bitmap(file='test3.png')
op <- par(mfrow = c(2,2))
spectrum(as.numeric(x),main='Observed')
spectrum(as.numeric(m$time.series[!is.na(m$time.series[,'trend']),'trend']),main='Trend')
spectrum(as.numeric(m$time.series[!is.na(m$time.series[,'seasonal']),'seasonal']),main='Seasonal')
spectrum(as.numeric(m$time.series[!is.na(m$time.series[,'remainder']),'remainder']),main='Remainder')
par(op)
dev.off()
bitmap(file='test4.png')
op <- par(mfrow = c(2,2))
cpgram(as.numeric(x),main='Observed')
cpgram(as.numeric(m$time.series[!is.na(m$time.series[,'trend']),'trend']),main='Trend')
cpgram(as.numeric(m$time.series[!is.na(m$time.series[,'seasonal']),'seasonal']),main='Seasonal')
cpgram(as.numeric(m$time.series[!is.na(m$time.series[,'remainder']),'remainder']),main='Remainder')
par(op)
dev.off()
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Seasonal Decomposition by Loess - Parameters',4,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Component',header=TRUE)
a<-table.element(a,'Window',header=TRUE)
a<-table.element(a,'Degree',header=TRUE)
a<-table.element(a,'Jump',header=TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Seasonal',header=TRUE)
a<-table.element(a,m$win['s'])
a<-table.element(a,m$deg['s'])
a<-table.element(a,m$jump['s'])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Trend',header=TRUE)
a<-table.element(a,m$win['t'])
a<-table.element(a,m$deg['t'])
a<-table.element(a,m$jump['t'])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Low-pass',header=TRUE)
a<-table.element(a,m$win['l'])
a<-table.element(a,m$deg['l'])
a<-table.element(a,m$jump['l'])
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,'Seasonal Decomposition by Loess - Time Series Components',6,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'t',header=TRUE)
a<-table.element(a,'Observed',header=TRUE)
a<-table.element(a,'Fitted',header=TRUE)
a<-table.element(a,'Seasonal',header=TRUE)
a<-table.element(a,'Trend',header=TRUE)
a<-table.element(a,'Remainder',header=TRUE)
a<-table.row.end(a)
for (i in 1:nx) {
a<-table.row.start(a)
a<-table.element(a,i,header=TRUE)
a<-table.element(a,x[i])
a<-table.element(a,x[i]+m$time.series[i,'remainder'])
a<-table.element(a,m$time.series[i,'seasonal'])
a<-table.element(a,m$time.series[i,'trend'])
a<-table.element(a,m$time.series[i,'remainder'])
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