Home » date » 2009 » Dec » 11 »

Shwws9_v2

*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, 11 Dec 2009 09:20:26 -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/11/t1260548485vqqdxulsnoxaqk7.htm/, Retrieved Fri, 11 Dec 2009 17:21:30 +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/11/t1260548485vqqdxulsnoxaqk7.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 «
102.1 102.86 102.99 103.73 105.02 104.43 104.63 104.93 105.87 105.66 106.76 106 107.22 107.33 107.11 108.86 107.72 107.88 108.38 107.72 108.41 109.9 111.45 112.18 113.34 113.46 114.06 115.54 116.39 115.94 116.97 115.94 115.91 116.43 116.26 116.35 117.9 117.7 117.53 117.86 117.65 116.51 115.93 115.31 115
 
Output produced by software:


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


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


Seasonal Decomposition by Loess - Time Series Components
tObservedFittedSeasonalTrendRemainder
1102.1101.717895878610.306364698881669102.175739422508-0.38210412139
2102.86102.8993128754050.207556324706251102.6131307998890.0393128754047325
3102.99102.933229652914-0.00375183018394935103.050522177270-0.0567703470857737
4103.73103.1769437186730.806249542265543103.476806739061-0.55305628132669
5105.02105.3981588165350.738749882612615103.9030913008530.378158816534807
6104.43104.559711418388-0.0180685164206585104.3183570980320.129711418388482
7104.63104.5087638828230.0176132219647960104.733622895212-0.121236117176593
8104.93105.460856641852-0.74262547011397105.1417688282620.530856641851742
9105.87106.867948991548-0.677863752860336105.5499147613130.99794899154766
10105.66105.788524369454-0.378163541538795105.9096391720850.128524369453999
11106.76107.2110506259060.0395857912375619106.2693635828570.451050625905538
12106105.751291797757-0.295647430392697106.544355632635-0.248708202242668
13107.22107.3142876187050.306364698881669106.8193476824140.0942876187045414
14107.33107.3806881360700.207556324706251107.0717555392240.0506881360697093
15107.11106.899588434150-0.00375183018394935107.324163396034-0.210411565850350
16108.86109.2711783654750.806249542265543107.6425720922590.411178365475124
17107.72106.7402693289030.738749882612615107.960980788484-0.979730671096974
18107.88107.372144245166-0.0180685164206585108.405924271255-0.507855754834068
19108.38107.891519024010.0176132219647960108.850867754025-0.488480975989887
20107.72106.783333443193-0.74262547011397109.399292026921-0.936666556806841
21108.41107.550147453044-0.677863752860336109.947716299817-0.85985254695619
22109.9109.594816271259-0.378163541538795110.583347270280-0.305183728741454
23111.45111.6414359680180.0395857912375619111.2189782407440.191435968018439
24112.18112.738054313861-0.295647430392697111.9175931165320.558054313860865
25113.34113.7574273087990.306364698881669112.6162079923200.417427308798679
26113.46113.4293531659140.207556324706251113.283090509379-0.0306468340855446
27114.06114.173778803745-0.00375183018394935113.9499730264390.113778803745021
28115.54115.7891204736260.806249542265543114.4846299841080.249120473625993
29116.39117.0219631756090.738749882612615115.0192869417780.631963175609371
30115.94116.481839384768-0.0180685164206585115.4162291316530.541839384768124
31116.97118.1092154565080.0176132219647960115.8131713215271.13921545650818
32115.94116.506054121162-0.74262547011397116.1165713489520.56605412116177
33115.91116.077892376483-0.677863752860336116.4199713763770.167892376482968
34116.43116.633709187523-0.378163541538795116.6044543540160.203709187523017
35116.26115.6914768771080.0395857912375619116.788937331654-0.568523122891762
36116.35116.189462522522-0.295647430392697116.806184907870-0.16053747747776
37117.9118.6702028170320.306364698881669116.8234324840870.77020281703166
38117.7118.4298775374520.207556324706251116.7625661378410.729877537452467
39117.53118.362052038588-0.00375183018394935116.7016997915960.832052038588046
40117.86118.2749709300820.806249542265543116.6387795276520.414970930082063
41117.65117.9853908536790.738749882612615116.5758592637090.335390853678533
42116.51116.535812073296-0.0180685164206585116.5022564431250.0258120732955263
43115.93115.4137331554940.0176132219647960116.428653622541-0.516266844506177
44115.31115.023630217753-0.74262547011397116.338995252361-0.286369782247007
45115114.428526870680-0.677863752860336116.249336882181-0.571473129320225
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2009/Dec/11/t1260548485vqqdxulsnoxaqk7/1k0ph1260548422.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/11/t1260548485vqqdxulsnoxaqk7/1k0ph1260548422.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/11/t1260548485vqqdxulsnoxaqk7/2xfgr1260548422.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/11/t1260548485vqqdxulsnoxaqk7/2xfgr1260548422.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/11/t1260548485vqqdxulsnoxaqk7/33hvh1260548422.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/11/t1260548485vqqdxulsnoxaqk7/33hvh1260548422.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/11/t1260548485vqqdxulsnoxaqk7/44dyk1260548423.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/11/t1260548485vqqdxulsnoxaqk7/44dyk1260548423.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