Home » date » 2010 » Dec » 09 »

*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: Thu, 09 Dec 2010 20:38:28 +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/09/t1291926992qpwq3icowgul4bo.htm/, Retrieved Thu, 09 Dec 2010 21:36:37 +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/09/t1291926992qpwq3icowgul4bo.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:
 
Dataseries X:
» Textbox « » Textfile « » CSV «
-820,8 993,3 741,7 603,6 -145,8 -35,1 395,1 523,1 462,3 183,4 791,5 344,8 -217,0 406,7 228,6 -580,1 -1550,4 -1447,5 -40,1 -1033,5 -925,6 -347,8 -447,7 -102,6 -2062,2 -929,7 -720,7 -1541,8 -1432,3 -1216,2 -212,8 -378,2 76,9 -101,3 220,4 495,6 -1035,2 61,8 -734,8 -6,9 -1061,1 -854,6 -186,5 244,0 -992,6 -335,2 316,8 477,6 -572,1 1115,2
 
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'George Udny Yule' @ 72.249.76.132


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


Seasonal Decomposition by Loess - Time Series Components
tObservedFittedSeasonalTrendRemainder
1-820.8-1379.03721817852-778.041359521869515.478577700385-558.237218178516
2993.3995.706139427682501.216043944357489.6778166279612.40613942768169
3741.7892.181774367612127.341170076851463.877055555537150.481774367612
4603.6887.2256684983-115.428436604596435.402768106295283.625668498301
5-145.865.7688876828117-764.297368339865406.928480657053211.568887682812
6-35.1155.779054149494-603.450748169431377.471694019937190.879054149494
7395.1166.563940875488275.621151741692348.014907382820-228.536059124513
8523.1605.565387553075126.498567905612314.13604454131482.4653875530746
9462.3700.491070647642-56.148252347449280.257181699807238.191070647642
10183.48.33500134328045146.059762237946212.405236418774-175.064998656720
11791.5914.229158145035524.217550717224144.553291137741122.729158145035
12344.822.4729375331551616.4120322366150.7150302302343-322.327062466845
13-217387.164590199142-778.041359521869-43.1232306772724604.164590199142
14406.7453.964825235055501.216043944357-141.78086917941147.2648252350546
15228.6570.297337604699127.341170076851-240.438507681550341.697337604699
16-580.1-710.74364592168-115.428436604596-334.027917473724-130.643645921679
17-1550.4-1908.88530439424-764.297368339865-427.617327265899-358.485304394237
18-1447.5-1769.87444590603-603.450748169431-521.674805924539-322.374445906029
19-40.1259.911132841488275.621151741692-615.73228458318300.011132841488
20-1033.5-1487.33448559823126.498567905612-706.164082307377-453.834485598234
21-925.6-998.455867620977-56.148252347449-796.595880031574-72.8558676209766
22-347.89.28291863559872146.059762237946-850.942680873544357.082918635599
23-447.7-514.32806900171524.217550717224-905.289481715514-66.6280690017102
24-102.690.6468282112164616.41203223661-912.258860447827193.246828211216
25-2062.2-2427.13040129799-778.041359521869-919.22823918014-364.93040129799
26-929.7-1472.30026168291501.216043944357-888.315782261451-542.600261682906
27-720.7-711.337844734089127.341170076851-857.4033253427629.3621552659115
28-1541.8-2169.37082611799-115.428436604596-798.800737277409-627.570826117995
29-1432.3-1360.10448244808-764.297368339865-740.19814921205672.1955175519208
30-1216.2-1164.66710665425-603.450748169431-664.28214517632351.532893345754
31-212.8-112.855010601102275.621151741692-588.3661411405999.9449893988981
32-378.2-366.205509072795126.498567905612-516.69305883281611.9944909272046
3376.9654.968228872491-56.148252347449-445.019976525042578.068228872491
34-101.345.0169196655904146.059762237946-393.676681903536146.316919665590
35220.4258.915836564805524.217550717224-342.33338728203038.5158365648053
36495.6693.260113935912616.41203223661-318.472146172523197.660113935912
37-1035.2-997.747735415115-778.041359521869-294.61090506301637.4522645848846
3861.8-78.6191091696023501.216043944357-298.996934774755-140.419109169602
39-734.8-1293.55820559036127.341170076851-303.382964486494-558.758205590357
40-6.9420.506694757021-115.428436604596-318.878258152425427.406694757021
41-1061.1-1023.52907984178-764.297368339865-334.37355181835637.5709201582212
42-854.6-802.76639643618-603.450748169431-302.98285539438951.8336035638204
43-186.5-377.028992771270275.621151741692-271.592158970423-190.528992771270
44244587.020774497149126.498567905612-225.519342402761343.020774497149
45-992.6-1749.60522181745-56.148252347449-179.446525835098-757.005221817453
46-335.2-683.776999818398146.059762237946-132.682762419548-348.576999818398
47316.8195.301448286772524.217550717224-85.9189990039966-121.498551713228
48477.6375.06887667921616.41203223661-36.2809089158208-102.53112332079
49-572.1-379.515821650486-778.04135952186913.3571811723551192.584178349514
501115.21661.64513349443501.21604394435767.538822561212546.445133494431
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/09/t1291926992qpwq3icowgul4bo/1lzm91291927104.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/09/t1291926992qpwq3icowgul4bo/1lzm91291927104.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/09/t1291926992qpwq3icowgul4bo/2lzm91291927104.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/09/t1291926992qpwq3icowgul4bo/2lzm91291927104.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/09/t1291926992qpwq3icowgul4bo/3w8mu1291927104.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/09/t1291926992qpwq3icowgul4bo/3w8mu1291927104.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/09/t1291926992qpwq3icowgul4bo/4w8mu1291927104.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/09/t1291926992qpwq3icowgul4bo/4w8mu1291927104.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