Home » date » 2010 » Dec » 14 »

*The author of this computation has been verified*
R Software Module: /rwasp_decompose.wasp (opens new window with default values)
Title produced by software: Classical Decomposition
Date of computation: Tue, 14 Dec 2010 20:45:19 +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/14/t12923594545lz15ffe7i2xhol.htm/, Retrieved Tue, 14 Dec 2010 21:44:14 +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/14/t12923594545lz15ffe7i2xhol.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 «
48154 57802 64781 47840 49709 26591 35263 40005 35908 30333 36287 44112 38390 48114 50736 46148 48033 21956 30600 43291 38127 33213 39636 51168 48929 62300 57657 56389 57276 23872 36577 46356 36860 34149 40059 50497 47472 48103 59723 49231 56126 21210 34865 41668 35193 33253 35704 46641 51145 51570 65540 54955 58552 20972 35681 37034 35645 33379 32747 49585 41745 48564 52518 45594 51442 25094 33702 39120 33842 29896 31481 43895 39477 53726 61465 50104 47460 26451 30306 42598 34485 29027 35489 40357 37532 43899 48572 43901 50556 18387 27534 38030 31917 26414 35306 38271 41454 52408 53536 53152 56421 21538 33625 42625 31295 33795 41227 45382 47206 46235 51378 46865 58608 21124 33591
 
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'Sir Ronald Aylmer Fisher' @ 193.190.124.24


Classical Decomposition by Moving Averages
tObservationsFitTrendSeasonalRandom
148154NANA1790.24305555555NA
257802NANA9602.62847222222NA
364781NANA14745.8836805556NA
447840NANA8467.75347222222NA
549709NANA11722.9930555556NA
626591NANA-19107.6006944444NA
73526333924.701388888942658.5833333333-8733.881944444451338.29861111111
84000541557.071180555541848.0833333333-291.012152777779-1552.07118055554
93590833904.888888888940859.2083333333-6954.319444444452003.11111111112
103033330212.352430555640203.5-9991.14756944445120.647569444445
113628734828.581597222240063.1666666667-5234.585069444441458.41840277778
124411243783.253472222239800.20833333333983.04513888889328.746527777766
133839041203.034722222239412.79166666671790.24305555555-2813.03472222222
144811448958.045138888939355.41666666679602.62847222222-844.04513888889
155073654330.675347222239584.791666666714745.8836805556-3594.67534722222
164614848265.003472222239797.258467.75347222222-2117.00347222223
174803351779.784722222240056.791666666711722.9930555556-3746.78472222223
182195621382.732638888940490.3333333333-19107.6006944444573.267361111102
193060032489.576388888941223.4583333333-8733.88194444445-1889.57638888889
204329141962.654513888942253.6666666667-291.0121527777791328.34548611112
213812736178.805555555543133.125-6954.319444444451948.19444444445
223321333857.060763888943848.2083333333-9991.14756944445-644.06076388889
233963639425.456597222244660.0416666667-5234.58506944444210.543402777774
245116849108.0451388889451253983.045138888892059.95486111111
254892947244.118055555645453.8751790.243055555551684.88194444444
266230055433.253472222245830.6259602.628472222226866.74652777779
275765760651.425347222245905.541666666714745.8836805556-2994.42534722222
285638954359.503472222245891.758467.753472222222029.49652777777
295727657671.368055555545948.37511722.9930555556-395.368055555547
302387226830.440972222245938.0416666667-19107.6006944444-2958.44097222222
313657737115.493055555645849.375-8733.88194444445-538.493055555555
324635644906.112847222245197.125-291.0121527777791449.88715277778
333686037737.347222222244691.6666666667-6954.31944444445-877.347222222226
343414934488.352430555644479.5-9991.14756944445-339.352430555555
354005938898.748263888944133.3333333333-5234.585069444441160.25173611111
365049747957.545138888943974.53983.045138888892539.45486111112
374747245582.493055555543792.251790.243055555551889.50694444445
384810353128.211805555543525.58333333339602.62847222222-5025.21180555555
395972358006.675347222243260.791666666714745.88368055561716.32465277778
404923151621.7534722222431548467.75347222222-2390.75347222222
415612654658.201388888942935.208333333311722.99305555561467.79861111111
422121023485.482638888942593.0833333333-19107.6006944444-2275.4826388889
433486533851.576388888942585.4583333333-8733.881944444451013.42361111111
444166842591.946180555542882.9583333333-291.012152777779-923.946180555547
453519336315.472222222243269.7916666667-6954.31944444445-1122.47222222223
463325333759.519097222243750.6666666667-9991.14756944445-506.519097222212
473570438855.664930555544090.25-5234.58506944444-3151.66493055555
484664148164.461805555644181.41666666673983.04513888889-1523.46180555555
495114545995.743055555644205.51790.243055555555149.25694444444
505157053649.045138888944046.41666666679602.62847222222-2079.04513888888
516554058618.050347222243872.166666666714745.88368055566921.94965277777
525495552364.003472222243896.258467.753472222222590.99652777777
535855255501.284722222243778.291666666711722.99305555563050.71527777778
542097224670.149305555643777.75-19107.6006944444-3698.14930555556
553568134774.868055555543508.75-8733.88194444445906.131944444453
563703442700.821180555642991.8333333333-291.012152777779-5666.82118055555
573564535369.680555555642324-6954.31944444445275.319444444438
583337931400.227430555641391.375-9991.147569444451978.77256944445
593274735470.498263888940705.0833333333-5234.58506944444-2723.49826388888
604958544563.628472222240580.58333333333983.045138888895021.37152777778
614174542460.118055555640669.8751790.24305555555-715.118055555555
624856450276.961805555640674.33333333339602.62847222222-1712.96180555555
635251855432.008680555640686.12514745.8836805556-2914.00868055555
644559448933.628472222240465.8758467.75347222222-3339.62847222222
655144251990.99305555564026811722.9930555556-548.993055555555
662509420870.565972222239978.1666666667-19107.60069444444223.43402777777
673370230912.701388888939646.5833333333-8733.881944444452789.29861111112
683912039476.154513888939767.1666666667-291.012152777779-356.154513888891
693384233400.722222222240355.0416666667-6954.31944444445441.277777777781
702989630924.602430555640915.75-9991.14756944445-1028.60243055555
713148135703.164930555640937.75-5234.58506944444-4222.16493055555
724389544811.420138888940828.3753983.04513888889-916.42013888889
733947742533.659722222240743.41666666671790.24305555555-3056.65972222222
745372650349.461805555640746.83333333339602.628472222223376.53819444445
756146555664.425347222240918.541666666714745.88368055565800.57465277778
765010449376.878472222240909.1258467.75347222222727.121527777781
774746052762.909722222241039.916666666711722.9930555556-5302.90972222222
782645121951.899305555641059.5-19107.60069444444499.10069444444
793030632097.159722222240831.0416666667-8733.88194444445-1791.15972222222
804259840049.529513888940340.5416666667-291.0121527777792548.47048611111
813448532439.555555555539393.875-6954.319444444452045.44444444445
822902728607.060763888938598.2083333333-9991.14756944445419.939236111109
833548933234.164930555638468.75-5234.585069444442254.83506944445
844035742244.795138888938261.753983.04513888889-1887.79513888889
853753239600.493055555637810.251790.24305555555-2068.49305555556
864389947107.045138888937504.41666666679602.62847222222-3208.04513888888
874857251952.967013888937207.083333333314745.8836805556-3380.96701388888
884390145458.961805555636991.20833333338467.75347222222-1557.96180555556
895055648597.701388888936874.708333333311722.99305555561958.29861111111
901838717672.565972222236780.1666666667-19107.6006944444714.434027777774
912753428122.784722222236856.6666666667-8733.88194444445-588.784722222226
923803037083.612847222237374.625-291.012152777779946.387152777781
933191730981.680555555637936-6954.31944444445935.319444444445
942641428537.144097222238528.2916666667-9991.14756944445-2123.14409722223
953530633923.539930555639158.125-5234.585069444441382.46006944445
963827143516.836805555639533.79166666673983.04513888889-5245.83680555555
974145441709.118055555539918.8751790.24305555555-255.118055555547
985240849966.753472222240364.1259602.628472222222441.24652777779
995353655275.550347222240529.666666666714745.8836805556-1739.55034722221
1005315249279.045138888940811.29166666678467.753472222223872.95486111112
1015642153088.534722222241365.541666666711722.99305555563332.46527777778
1022153822800.940972222241908.5416666667-19107.6006944444-1262.94097222223
1033362533710.618055555642444.5-8733.88194444445-85.6180555555547
1044262542135.946180555542426.9583333333-291.012152777779489.053819444453
1053129535125.513888888942079.8333333333-6954.31944444445-3830.51388888888
1063379531736.810763888941727.9583333333-9991.147569444452058.18923611112
1074122736322.539930555641557.125-5234.585069444444904.46006944445
1084538245614.0451388889416313983.04513888889-232.045138888891
10947206NA41612.3333333333NANA
11046235NANANANA
11151378NANANANA
11246865NANANANA
11358608NANANANA
11421124NANANANA
11533591NANANANA
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923594545lz15ffe7i2xhol/17aye1292359515.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923594545lz15ffe7i2xhol/17aye1292359515.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t12923594545lz15ffe7i2xhol/27aye1292359515.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923594545lz15ffe7i2xhol/27aye1292359515.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t12923594545lz15ffe7i2xhol/301fh1292359515.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923594545lz15ffe7i2xhol/301fh1292359515.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t12923594545lz15ffe7i2xhol/401fh1292359515.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923594545lz15ffe7i2xhol/401fh1292359515.ps (open in new window)


 
Parameters (Session):
par1 = additive ; par2 = 12 ;
 
Parameters (R input):
par1 = additive ; 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