Home » date » 2010 » Dec » 26 »

Paper

*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: Sun, 26 Dec 2010 13:17:46 +0000
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2010/Dec/26/t12933694060m4lghkb2mtwr7h.htm/, Retrieved Sun, 26 Dec 2010 14:16:50 +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/2010/Dec/26/t12933694060m4lghkb2mtwr7h.htm/},
    year = {2010},
}
@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 = {2010},
    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:
Loess
 
Dataseries X:
» Textbox « » Textfile « » CSV «
548604 563668 586111 604378 600991 544686 537034 551531 563250 574761 580112 575093 557560 564478 580523 596594 586570 536214 523597 536535 536322 532638 528222 516141 501866 506174 517945 533590 528379 477580 469357 490243 492622 507561 516922 514258 509846 527070 541657 564591 555362 498662 511038 525919 531673 548854 560576 557274 565742 587625 619916 625809 619567 572942 572775 574205 579799 590072 593408 597141 595404
 
Output produced by software:


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


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


Seasonal Decomposition by Loess - Time Series Components
tObservedFittedSeasonalTrendRemainder
1548604543214.858399259-9567.47830465812563560.619905399-5389.14160074084
2563668561168.9621592251721.76984394179564445.267996833-2499.03784077521
3586111586339.49857420520552.5853375265565329.916088268228.498574205441
4604378606684.36837557435958.266637269566113.3649871572306.36837557389
5600991606301.84220712428783.34390683566896.8138860465310.84220712376
6544686545553.498538309-23757.5300625179567576.031524209867.498538308777
7537034533210.754652384-27398.0038147558568255.249162372-3823.24534761626
8551531549431.762607737-15154.9143988771568785.15179114-2099.23739226290
9563250567976.578285036-10791.6327049442569315.0544199084726.57828503638
10574761581919.303230043-1482.70110253999569085.3978724977158.30323004338
11580112588515.2270743152853.03160059949568855.7413250858403.22707431507
12575093584136.975044412-1716.74683928251567765.771794879043.97504441242
13557560558011.676040003-9567.47830465812566675.802264655451.676040003193
14564478562426.2154471851721.76984394179564808.014708874-2051.78455281537
15580523577553.18750938120552.5853375265562940.227153092-2969.81249061867
16596594597470.98097812535958.266637269559758.752384606876.980978125357
17586570587779.37847705128783.34390683556577.2776161191209.37847705092
18536214543876.677665202-23757.5300625179552308.8523973167662.67766520171
19523597526551.576636242-27398.0038147558548040.4271785132954.57663624245
20536535545182.619623422-15154.9143988771543042.2947754558647.61962342204
21536322545391.470332548-10791.6327049442538044.1623723979069.47033254756
22532638534097.837313636-1482.70110253999532660.8637889041459.83731363621
23528222526313.403193992853.03160059949527277.565205411-1908.59680601046
24516141511833.711495758-1716.74683928251522165.035343524-4307.28850424156
25501866496246.972823021-9567.47830465812517052.505481637-5619.02717697911
26506174497544.5508760161721.76984394179513081.679280042-8629.44912398409
27517945506226.56158402620552.5853375265509110.853078447-11718.4384159739
28533590524207.90130318935958.266637269507013.832059542-9382.09869681083
29528379523057.84505253428783.34390683504916.811040636-5321.15494746628
30477580474008.676563032-23757.5300625179504908.853499486-3571.32343696826
31469357461211.10785642-27398.0038147558504900.895958336-8145.89214358025
32490243489177.651277906-15154.9143988771506463.263120971-1065.34872209409
33492622488010.002421338-10791.6327049442508025.630283606-4611.99757866206
34507561506246.680986077-1482.70110253999510358.020116463-1314.31901392271
35516922518300.5584500812853.03160059949512690.4099493191378.55845008139
36514258514934.236468609-1716.74683928251515298.510370674676.236468608782
37509846511352.86751263-9567.47830465812517906.6107920281506.86751262983
38527070531573.2062445551721.76984394179520845.0239115034503.20624455542
39541657538977.97763149620552.5853375265523783.437030977-2679.02236850373
40564591566151.08186390835958.266637269527072.6514988231560.08186390763
41555362551578.790126528783.34390683530361.865966669-3783.20987349947
42498662486797.638395869-23757.5300625179534283.891666648-11864.3616041306
43511038511268.086448128-27398.0038147558538205.917366627230.086448128219
44525919523708.345066615-15154.9143988771543284.569332262-2210.6549333852
45531673525774.411407047-10791.6327049442548363.221297897-5898.58859295293
46548854544999.878301141-1482.70110253999554190.822801399-3854.1216988588
47560576558280.54409452853.03160059949560018.424304901-2295.4559055001
48557274550525.176751508-1716.74683928251565739.570087774-6748.8232484915
49565742569590.76243401-9567.47830465812571460.7158706483848.76243401051
50587625597332.9834644521721.76984394179576195.2466916069707.98346445174
51619916638349.63714990820552.5853375265580929.77751256518433.6371499082
52625809631821.48799005535958.266637269583838.2453726766012.48799005535
53619567623603.94286038428783.34390683586746.7132327864036.94286038389
54572942580803.304055867-23757.5300625179588838.2260066517861.30405586702
55572775582018.26503424-27398.0038147558590929.7387805169243.2650342402
56574205570676.153495563-15154.9143988771592888.760903314-3528.84650443716
57579799575541.849678831-10791.6327049442594847.783026113-4257.15032116859
58590072585058.449586536-1482.70110253999596568.251516004-5013.55041346408
59593408585674.2483935052853.03160059949598288.720005895-7733.75160649477
60597141596175.917599874-1716.74683928251599822.829239409-965.082400126266
61595404599018.539831736-9567.47830465812601356.9384729223614.53983173566
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/26/t12933694060m4lghkb2mtwr7h/188d01293369463.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/26/t12933694060m4lghkb2mtwr7h/188d01293369463.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/26/t12933694060m4lghkb2mtwr7h/288d01293369463.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/26/t12933694060m4lghkb2mtwr7h/288d01293369463.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/26/t12933694060m4lghkb2mtwr7h/3jzc31293369463.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/26/t12933694060m4lghkb2mtwr7h/3jzc31293369463.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/26/t12933694060m4lghkb2mtwr7h/4c8t61293369463.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/26/t12933694060m4lghkb2mtwr7h/4c8t61293369463.ps (open in new window)


 
Parameters (Session):
par1 = 12 ; par2 = periodic ; par3 = 0 ; par5 = 1 ; par7 = 1 ; par8 = FALSE ;
 
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