Home » date » 2009 » Dec » 04 »

ws9

*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 12:53:56 -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/t12599565848ej9h0kt4hnomo8.htm/, Retrieved Fri, 04 Dec 2009 20:56:29 +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/t12599565848ej9h0kt4hnomo8.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:
ws9.9
 
Dataseries X:
» Textbox « » Textfile « » CSV «
126.51 131.02 136.51 138.04 132.92 129.61 122.96 124.04 121.29 124.56 118.53 113.14 114.15 122.17 129.23 131.19 129.12 128.28 126.83 138.13 140.52 146.83 135.14 131.84 125.7 128.98 133.25 136.76 133.24 128.54 121.08 120.23 119.08 125.75 126.89 126.6 121.89 123.44 126.46 129.49 127.78 125.29 119.02 119.96 122.86 131.89 132.73 135.01 136.71 142.73 144.43 144.93 138.75 130.22 122.19 128.4 140.43 153.5 149.33 142.97
 
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
1126.51123.838897343835-4.5918005989784133.772903255143-2.67110265616452
2131.02129.3086880779180.138482229739662132.592829692342-1.71131192208190
3136.51137.1064776134664.50076625699235131.4127561295420.596477613466021
4138.04139.3494048325386.49900336878182130.2315917986801.30940483253787
5132.92134.1183315510222.67124098115847129.0504274678191.19833155102251
6129.61132.826406712296-1.52509748305060127.9186907707553.21640671229549
7122.96126.852482426437-7.71943650012788126.7869540736913.89248242643669
8124.04126.555044457224-4.20978257221519125.7347381149912.51504445722391
9121.29119.649607995001-1.75213015129263124.682522156291-1.64039200499874
10124.56119.5364718086285.72707326460173123.856454926770-5.02352819137209
11118.53112.4753335532461.55427874950482123.030387697249-6.05466644675418
12113.14104.515928357071-1.29259843532114123.056670078250-8.6240716429291
13114.15109.808848139727-4.5918005989784123.082952459251-4.34115186027273
14122.17120.0272998036030.138482229739662124.174217966657-2.14270019639709
15129.23128.6937502689444.50076625699235125.265483474064-0.53624973105606
16131.19128.8365601710726.49900336878182127.044436460146-2.35343982892822
17129.12126.7453695726122.67124098115847128.823389446229-2.37463042738753
18128.28127.735098199716-1.52509748305060130.349999283335-0.544901800283981
19126.83129.502827379688-7.71943650012788131.876609120442.67282737968785
20138.13147.790655660336-4.20978257221519132.6791269118799.66065566033603
21140.52149.310485447974-1.75213015129263133.4816447033188.7904854479743
22146.83154.2499197238175.72707326460173133.6830070115827.41991972381663
23135.14134.8413519306501.55427874950482133.884369319845-0.298648069349781
24131.84131.520839315356-1.29259843532114133.451759119965-0.319160684643975
25125.7122.972651678893-4.5918005989784133.019148920085-2.72734832110692
26128.98125.9309569467430.138482229739662131.890560823517-3.04904305325715
27133.25131.2372610160584.50076625699235130.761972726950-2.01273898394203
28136.76137.4521932617486.49900336878182129.568803369470.692193261748059
29133.24135.4331250068512.67124098115847128.3756340119912.19312500685101
30128.54130.943318536748-1.52509748305060127.6617789463032.40331853674766
31121.08122.931512619513-7.71943650012788126.9479238806151.85151261951258
32120.23118.241497062424-4.20978257221519126.428285509791-1.98850293757611
33119.08114.003483012325-1.75213015129263125.908647138967-5.07651698767468
34125.75120.3602733537695.72707326460173125.412653381629-5.38972664623063
35126.89127.3090616262051.55427874950482124.9166596242910.41906162620468
36126.6129.815414265316-1.29259843532114124.6771841700053.21541426531593
37121.89123.934091883258-4.5918005989784124.437708715722.04409188325849
38123.44122.2124522074830.138482229739662124.529065562777-1.22754779251665
39126.46123.7988113331744.50076625699235124.620422409834-2.66118866682640
40129.49127.5236970407206.49900336878182124.957299590498-1.96630295928028
41127.78127.5945822476792.67124098115847125.294176771163-0.185417752321342
42125.29126.037330163208-1.52509748305060126.0677673198430.747330163207522
43119.02118.918078631605-7.71943650012788126.841357868523-0.101921368395423
44119.96115.959921852565-4.20978257221519128.16986071965-4.00007814743475
45122.86117.973766580516-1.75213015129263129.498363570777-4.88623341948391
46131.89127.2065739483575.72707326460173130.846352787041-4.68342605164267
47132.73131.7113792471901.55427874950482132.194342003305-1.01862075281016
48135.01138.194081434020-1.29259843532114133.1185170013013.1840814340203
49136.71143.969108599682-4.5918005989784134.0426919992967.2591085996821
50142.73150.4429346686440.138482229739662134.8785831016167.71293466864418
51144.43148.6447595390724.50076625699235135.7144742039364.21475953907168
52144.93146.7133409937496.49900336878182136.6476556374691.78334099374891
53138.75137.2479219478392.67124098115847137.580837071003-1.50207805216104
54130.22123.495875217497-1.52509748305060138.469222265553-6.7241247825028
55122.19112.741829040024-7.71943650012788139.357607460104-9.44817095997632
56128.4120.846209507489-4.20978257221519140.163573064726-7.55379049251053
57140.43141.642591481945-1.75213015129263140.9695386693471.21259148194540
58153.5159.4697165003825.72707326460173141.8032102350165.96971650038182
59149.33154.4688394498101.55427874950482142.6368818006865.13883944980952
60142.97143.699372329758-1.29259843532114143.5332261055630.72937232975849
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2009/Dec/04/t12599565848ej9h0kt4hnomo8/16kgq1259956434.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/04/t12599565848ej9h0kt4hnomo8/16kgq1259956434.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/04/t12599565848ej9h0kt4hnomo8/237dn1259956434.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/04/t12599565848ej9h0kt4hnomo8/237dn1259956434.ps (open in new window)


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


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


 
Parameters (Session):
par1 = FALSE ; par2 = 0.5 ; par3 = 1 ; par4 = 1 ; par5 = 12 ; par6 = 3 ; par7 = 1 ; par8 = 2 ; par9 = 1 ;
 
Parameters (R input):
par1 = 12 ; par2 = periodic ; par3 = 0 ; par5 = 1 ; par7 = 1 ; par8 = FALSE ; par9 = 1 ;
 
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