Home » date » 2010 » Jun » 02 »

*Unverified author*
R Software Module: /rwasp_decompose.wasp (opens new window with default values)
Title produced by software: Classical Decomposition
Date of computation: Wed, 02 Jun 2010 12:20:40 +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/Jun/02/t1275481291zub0hotqiftu3f2.htm/, Retrieved Wed, 02 Jun 2010 14:21:31 +0200
 
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/Jun/02/t1275481291zub0hotqiftu3f2.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:
KDGP2W52
 
Dataseries X:
» Textbox « » Textfile « » CSV «
306 303 344 254 309 310 379 294 356 318 405 545 268 243 273 273 236 222 302 285 309 322 362 471 198 253 173 186 185 105 228 214 189 270 277 378 185 182 258 179 197 168 250 211 260 234 305 347 203 217 227 242 185 175 252 319 202 254 336 431 150 280 187 279 193 227 225 205 259 254 275 394 159 230 188 195 189 220 274
 
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'Sir Ronald Aylmer Fisher' @ 193.190.124.24


Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
1306NANA0.773736976398098NA
2303NANA0.91790475263952NA
3344NANA0.87772387028514NA
4254NANA0.909893385186033NA
5309NANA0.790146803304475NA
6310NANA0.711898353475538NA
7379346.7857031831313421.013993284161201.09289395877966
8294336.862568840931337.9166666666670.996880598296220.872759478773758
9356328.149381087313332.4583333333330.9870391209544461.08487177035167
10318360.042198137483330.2916666666671.090073515239010.883229803742534
11405417.510001755997328.0416666666671.272734668124470.970036641748985
12545532.762527915388321.3333333333331.657974671935851.02296984386739
13268243.308040036519314.4583333333330.7737369763980981.10148435686620
14243285.353639976811310.8750.917904752639520.851574909013767
15273270.814385810894308.5416666666670.877723870285141.00807052469743
16273279.109795905816306.750.9098933851860330.978109704512566
17236241.093543358278305.1250.7901468033044750.978873165629705
18222213.74748063103300.250.7118983534755381.03860873281223
19302298.367523864434294.251.013993284161201.01217450240066
20285290.839914552922291.750.996880598296220.979920518949749
21309284.2672668348802880.9870391209544461.08700520971163
22322305.44768291593280.2083333333331.090073515239011.05419035078628
23362349.312635788994274.4583333333331.272734668124471.03632094264884
24471443.439142464843267.4583333333331.657974671935851.06215251405629
25198200.784745375306259.50.7737369763980980.986130692498072
26253232.650608762758253.4583333333330.917904752639521.08746760365451
27173215.481210155002245.50.877723870285140.802854225087914
28186216.857923469338238.3333333333330.9098933851860330.857704422436282
29185183.807900118704232.6250.7901468033044751.00648557477957
30105160.32544168897225.2083333333330.7118983534755380.654917890098186
31228223.881267198759220.7916666666671.013993284161201.01839695144116
32214216.613846671449217.2916666666670.996880598296220.987933150573638
33189215.05114847795217.8750.9870391209544460.878860686574659
34270241.042506057225221.1251.090073515239011.12013438798176
35277281.698606544882221.3333333333331.272734668124470.983320448040153
36378372.146231571602224.4583333333331.657974671935851.01572975333830
37185176.4120306187662280.7737369763980981.04868131357658
38182210.008958197650228.7916666666670.917904752639520.866629697904174
39258203.302791454796231.6250.877723870285141.26904307685006
40179212.080983197111233.0833333333330.9098933851860330.844017211263278
41197183.906668469117232.750.7901468033044751.07119552346783
42168165.605354477247232.6250.7118983534755381.01445995227819
43250235.330941365746232.0833333333331.013993284161201.06233374391452
44211233.560816842485234.2916666666670.996880598296220.903404958299575
45260231.419547233778234.4583333333330.9870391209544461.12350059927025
46234257.030250947397235.7916666666671.090073515239010.910398675399066
47305302.804789791279237.9166666666671.272734668124471.007249588787
48347394.114395974752237.7083333333331.657974671935850.880455024084504
49203184.213878464114238.0833333333330.7737369763980981.10197994685588
50217222.744886640524242.6666666666670.917904752639520.974208671062358
51227214.822917252288244.750.877723870285141.05668428165609
52242221.255741497737243.1666666666670.9098933851860331.09375692744441
53185193.816426293893245.2916666666670.7901468033044750.95451145982578
54175178.033913231674250.0833333333330.7118983534755380.982958790397838
55252254.892561806022251.3751.013993284161200.98865183909045
56319251.006227312669251.7916666666670.996880598296221.27088480399585
57202249.474137821236252.750.9870391209544460.8097031690906
58254275.379821787254252.6251.090073515239010.922362424201977
59336323.910973037677254.51.272734668124471.03732206676715
60431426.0994906875142571.657974671935851.01150085700543
61150199.656378951393258.0416666666670.7737369763980980.751290796656782
62280231.464981790599252.1666666666670.917904752639521.20968622481870
63187219.248108431642249.7916666666670.877723870285140.852914998162018
64279229.444781964411252.1666666666670.9098933851860331.21597884079698
65193197.240395774880249.6250.7901468033044750.978501382750624
66227174.800708209639245.5416666666670.7118983534755381.29862174086708
67225247.794608816894244.3751.013993284161200.908010069606729
68205241.909691853216242.6666666666670.996880598296220.847423674634699
69259237.506288479664240.6250.9870391209544461.09049744180637
70254258.529102030851237.1666666666671.090073515239010.982481268084432
71275297.183545007063233.51.272734668124470.92535406021038
72394386.377180839051233.0416666666671.657974671935851.01972895796899
73159NA234.791666666667NANA
74230NANANANA
75188NANANANA
76195NANANANA
77189NANANANA
78220NANANANA
79274NANANANA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Jun/02/t1275481291zub0hotqiftu3f2/12pcl1275481236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jun/02/t1275481291zub0hotqiftu3f2/12pcl1275481236.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jun/02/t1275481291zub0hotqiftu3f2/2dhto1275481236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jun/02/t1275481291zub0hotqiftu3f2/2dhto1275481236.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jun/02/t1275481291zub0hotqiftu3f2/3o8a91275481236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jun/02/t1275481291zub0hotqiftu3f2/3o8a91275481236.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Jun/02/t1275481291zub0hotqiftu3f2/4o8a91275481236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Jun/02/t1275481291zub0hotqiftu3f2/4o8a91275481236.ps (open in new window)


 
Parameters (Session):
par1 = multiplicative ; par2 = 12 ;
 
Parameters (R input):
par1 = multiplicative ; par2 = 12 ;
 
R code (references can be found in the software module):
par2 <- as.numeric(par2)
x <- ts(x,freq=par2)
m <- decompose(x,type=par1)
m$figure
bitmap(file='test1.png')
plot(m)
dev.off()
mylagmax <- length(x)/2
bitmap(file='test2.png')
op <- par(mfrow = c(2,2))
acf(as.numeric(x),lag.max = mylagmax,main='Observed')
acf(as.numeric(m$trend),na.action=na.pass,lag.max = mylagmax,main='Trend')
acf(as.numeric(m$seasonal),na.action=na.pass,lag.max = mylagmax,main='Seasonal')
acf(as.numeric(m$random),na.action=na.pass,lag.max = mylagmax,main='Random')
par(op)
dev.off()
bitmap(file='test3.png')
op <- par(mfrow = c(2,2))
spectrum(as.numeric(x),main='Observed')
spectrum(as.numeric(m$trend[!is.na(m$trend)]),main='Trend')
spectrum(as.numeric(m$seasonal[!is.na(m$seasonal)]),main='Seasonal')
spectrum(as.numeric(m$random[!is.na(m$random)]),main='Random')
par(op)
dev.off()
bitmap(file='test4.png')
op <- par(mfrow = c(2,2))
cpgram(as.numeric(x),main='Observed')
cpgram(as.numeric(m$trend[!is.na(m$trend)]),main='Trend')
cpgram(as.numeric(m$seasonal[!is.na(m$seasonal)]),main='Seasonal')
cpgram(as.numeric(m$random[!is.na(m$random)]),main='Random')
par(op)
dev.off()
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Classical Decomposition by Moving Averages',6,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'t',header=TRUE)
a<-table.element(a,'Observations',header=TRUE)
a<-table.element(a,'Fit',header=TRUE)
a<-table.element(a,'Trend',header=TRUE)
a<-table.element(a,'Seasonal',header=TRUE)
a<-table.element(a,'Random',header=TRUE)
a<-table.row.end(a)
for (i in 1:length(m$trend)) {
a<-table.row.start(a)
a<-table.element(a,i,header=TRUE)
a<-table.element(a,x[i])
if (par1 == 'additive') a<-table.element(a,m$trend[i]+m$seasonal[i]) else a<-table.element(a,m$trend[i]*m$seasonal[i])
a<-table.element(a,m$trend[i])
a<-table.element(a,m$seasonal[i])
a<-table.element(a,m$random[i])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable.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