Home » date » 2010 » Nov » 20 »

WS7 - Deterministische trend

*The author of this computation has been verified*
R Software Module: /rwasp_multipleregression.wasp (opens new window with default values)
Title produced by software: Multiple Regression
Date of computation: Sat, 20 Nov 2010 18:14:50 +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/Nov/20/t1290276818jlf3r91c8p1d0p0.htm/, Retrieved Sat, 20 Nov 2010 19:13:49 +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/Nov/20/t1290276818jlf3r91c8p1d0p0.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 «
13 13 14 13 3 1 12 12 8 13 5 1 15 10 12 16 6 1 12 9 7 12 6 1 10 10 10 11 5 1 12 12 7 12 3 1 15 13 16 18 8 1 9 12 11 11 4 1 12 12 14 14 4 1 11 6 6 9 4 1 11 5 16 14 6 1 11 12 11 12 6 1 15 11 16 11 5 1 7 14 12 12 4 1 11 14 7 13 6 1 11 12 13 11 4 1 10 12 11 12 6 1 14 11 15 16 6 1 10 11 7 9 4 2 6 7 9 11 4 2 11 9 7 13 2 2 15 11 14 15 7 2 11 11 15 10 5 2 12 12 7 11 4 2 14 12 15 13 6 2 15 11 17 16 6 2 9 11 15 15 7 2 13 8 14 14 5 2 13 9 14 14 6 2 16 12 8 14 4 2 13 10 8 8 4 2 12 10 14 13 7 2 14 12 14 15 7 2 11 8 8 13 4 3 9 12 11 11 4 3 16 11 16 15 6 3 12 12 10 15 6 3 10 7 8 9 5 3 13 11 14 13 6 3 16 11 16 16 7 3 14 12 13 13 6 3 15 9 5 11 3 3 5 15 8 12 3 3 8 11 10 12 4 3 11 11 8 12 6 3 16 11 13 14 7 3 17 11 15 14 5 3 9 15 6 8 4 3 9 11 12 13 5 3 13 12 16 16 6 3 10 12 5 13 6 3 6 9 15 11 6 4 12 12 12 14 5 4 8 12 8 13 4 4 14 13 13 13 5 4 12 11 14 13 5 4 11 9 12 12 4 4 16 9 16 16 6 4 8 11 10 15 2 4 15 11 15 15 8 4 7 12 8 12 3 4 16 12 16 14 6 4 14 9 19 12 6 4 16 11 etc...
 
Output produced by software:

Enter (or paste) a matrix (table) containing all data (time) series. Every column represents a different variable and must be delimited by a space or Tab. Every row represents a period in time (or category) and must be delimited by hard returns. The easiest way to enter data is to copy and paste a block of spreadsheet cells. Please, do not use commas or spaces to seperate groups of digits!


Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time9 seconds
R Server'George Udny Yule' @ 72.249.76.132


Multiple Linear Regression - Estimated Regression Equation
Popularity[t] = + 0.184727929928006 + 0.102458915938333FindingFriends[t] + 0.241835431638646KnowingPeople[t] + 0.349828593066031Liked[t] + 0.637259261836312Celebrity[t] + 0.0988008593457308Date[t] -0.0064127230084315t + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)0.1847279299280061.4561140.12690.8992190.44961
FindingFriends0.1024589159383330.0977071.04860.2960430.148022
KnowingPeople0.2418354316386460.0618463.91030.000147e-05
Liked0.3498285930660310.097953.57150.0004780.000239
Celebrity0.6372592618363120.1581234.03028.9e-054.4e-05
Date0.09880085934573080.1967060.50230.6162150.308107
t-0.00641272300843150.011948-0.53670.5922470.296123


Multiple Linear Regression - Regression Statistics
Multiple R0.707225438473912
R-squared0.500167820824616
Adjusted R-squared0.480040350522252
F-TEST (value)24.8500091323379
F-TEST (DF numerator)6
F-TEST (DF denominator)149
p-value0
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation2.11754990906277
Sum Squared Residuals668.118624988388


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
11311.45432751177201.54567248822804
21211.1689618066660.831038193334013
31513.61171801936991.38828198063014
41210.89435484996581.10564515003425
51010.7288194829093-0.728819482909259
6129.277128366254972.72287163374503
71516.8349613115104-1.83496131151042
8910.5190753155630-1.51907531556297
91212.2876546666686-0.287654666668564
10117.982662029590823.01733797040918
111113.3158061960333-2.31580619603329
121112.1177715402679-1.11777154026790
131512.23098920461202.76901079538798
14711.2771808340937-4.27718083409372
151111.6859380696307-0.685938069630715
161110.95144439477280.048555605227192
171012.0857079252257-2.08570792522574
181414.3434923850977-0.343492385097678
19108.777878393190981.22212160680902
2069.54495805583857-3.54495805583857
21118.684930963888952.31506903611105
221514.46223758954130.537762410458681
231111.6739988091688-0.673998809168759
24129.547930880219212.45206911978079
251413.45037732012460.54962267987537
261514.87466232365320.125337676346752
27914.6720094061378-5.67200940613781
281312.49203738693710.507962613062922
291313.2253428417033-0.225342841703291
301610.80077575300545.19922424699464
31138.490473639724084.50952636027592
321213.5959942573866-1.59599425738661
331414.4941565523869-0.494156552386905
341110.1142614634980.885738536501996
35910.5435335130268-1.54353351302678
361614.317671928211.68232807179001
371212.9627055313080-0.962705531308015
38109.224096545098140.775903454901863
391313.1151057097753-0.115105709775342
401615.27910889107860.720891108921396
411412.96290374805821.03709625194183
42158.102995852484586.89700414751543
4359.7866715130881-4.78667151308811
44810.4913532514399-2.49135325143995
451111.2757881888268-0.275788188826849
461613.81546907198002.18453092801998
471713.01820868857633.98179131142375
4898.508881924340850.491118075659151
49911.9300483545774-2.93004835457742
501314.6801813150963-1.68018131509631
511010.9640930648647-0.964093064864686
52612.4678015836414-6.46780158364138
531212.4554858308938-0.455485830893791
54810.4946435264284-2.49464352642844
551412.43712613938791.56287386061212
561212.4676310161414-0.467631016141426
571110.78554174307670.214458256923304
581614.42030364255961.57969635744041
59810.2689305211847-2.26893052118467
601515.2952505273873-0.295250527387342
6179.46266661046707-2.46266661046707
621614.00237231220881.99762768779120
631413.71443195016930.285568049830749
641613.75324568004232.24675431995765
6599.92048663101368-0.920486631013682
661412.26412727035681.73587272964320
671113.0288160793959-2.02881607939594
681310.45046064144202.54953935855797
691512.98094922251352.01905077748645
7055.65526965476048-0.65526965476048
711512.47024103036072.52975896963932
721312.32445179165190.67554820834806
731112.0817378824939-1.08173788249391
741113.9752819157442-2.97528191574416
751212.4957196209476-0.495719620947646
761213.4197310247318-1.41973102473182
771212.2868539311207-0.28685393112073
781211.87613978984800.123860210151980
791410.78295490362943.21704509637059
8067.96886701447297-1.96886701447297
8179.82863683984184-2.82863683984184
821411.93300173470792.06699826529209
831413.83819796365530.161802036344738
841011.2090818273308-1.20908182733078
85138.682055822694514.31794417730549
861212.3827278226039-0.382727822603868
8799.32868069070524-0.328680690705235
881212.0243408260259-0.0243408260258719
891615.06504784719560.934952152804356
901010.2509351394506-0.250935139450646
911413.16019074401760.839809255982396
921013.5294557228591-3.52945572285908
931615.33809606560730.66190393439274
941513.44002046968781.55997953031224
951211.33980164952210.660198350477908
96109.723253692633710.276746307366286
97810.2113803731837-2.21138037318372
9888.5839638760142-0.583963876014196
991112.7817660837874-1.78176608378740
1001312.39728480532060.602715194679391
1011615.42617079724010.573829202759879
1021614.68871753382671.31128246617330
1031415.783120023334-1.78312002333400
104118.803925706069412.19607429393059
10546.86893251038793-2.86893251038793
1061414.5434362544404-0.543436254440421
107910.3345009862217-1.33450098622172
1081415.2838424010198-1.28384240101982
109810.4296687016322-2.42966870163224
110810.8611316540725-2.86113165407251
1111112.1750326425653-1.17503264256529
1121213.6138983132027-1.61389831320273
1131111.4453785390021-0.445378539002147
1141413.58963559195770.41036440804235
1151514.32847529221290.671524707787085
1161613.36635806857512.63364193142493
1171613.46240426150502.53759573849503
1181112.7046361347967-1.70463613479673
1191413.69141424712680.308585752873246
1201410.88286060345943.11713939654063
1211211.32873538945530.6712646105447
1221412.47463614583341.5253638541666
123810.1381161395181-2.13811613951814
1241313.7618095480229-0.76180954802293
1251613.65293790907622.34706209092383
1261210.83274703948361.16725296051639
1271615.37245274122530.627547258774659
1281213.2838711469848-1.28387114698484
1291111.3710149332596-0.371014933259569
13046.26171529119994-2.26171529119994
1311615.34680184919160.653198150808385
1321512.43025504409682.56974495590315
1331011.3339267659976-1.33392676599763
1341313.0801691844501-0.0801691844500615
1351513.10513981571461.89486018428544
1361210.50703824941291.49296175058711
1371413.47352631703670.526473682963345
138710.573267534394-3.573267534394
1391914.01178923936994.98821076063011
1401212.5715353979438-0.571535397943801
1411212.1641645992487-0.164164599248651
1421313.4008870456399-0.400887045639915
1431512.81961298509092.18038701490908
14488.14265477299094-0.142654772990940
1451210.78996003332141.21003996667862
1461010.7095121600920-0.709512160092034
147811.2805515789296-3.28055157892957
1481014.261451480109-4.261451480109
1491513.73720993191991.26279006808015
1501614.58906237437961.41093762562044
1511313.2420751468102-0.242075146810151
1521615.11311341385410.88688658614592
153910.6373404646853-1.63734046468531
1541413.57797942352520.422020576474804
1551413.10821070053430.891789299465702
1561210.52691182139671.47308817860326


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
100.07385393424063790.1477078684812760.926146065759362
110.1114121685982580.2228243371965160.888587831401742
120.07345787413724060.1469157482744810.92654212586276
130.548827345484510.902345309030980.45117265451549
140.7186992086308220.5626015827383550.281300791369178
150.6520904123102280.6958191753795450.347909587689772
160.5761124921378210.8477750157243570.423887507862179
170.489204168649930.978408337299860.51079583135007
180.4518794925294630.9037589850589270.548120507470537
190.3660004165063050.732000833012610.633999583493695
200.5100387405013010.9799225189973990.489961259498699
210.5164266747214250.967146650557150.483573325278575
220.5458465860458270.9083068279083470.454153413954173
230.4723615361310520.9447230722621040.527638463868948
240.4779454316082210.9558908632164430.522054568391779
250.4347313659746490.8694627319492980.565268634025351
260.3743861511192350.748772302238470.625613848880765
270.6200735979705190.7598528040589610.379926402029481
280.5749546427581560.8500907144836880.425045357241844
290.5197605362760810.9604789274478380.480239463723919
300.7117639701334920.5764720597330170.288236029866508
310.8125705987111380.3748588025777250.187429401288862
320.7768257167972980.4463485664054050.223174283202702
330.7307830950400260.5384338099199480.269216904959974
340.6978619859844220.6042760280311560.302138014015578
350.695750871668920.608498256662160.30424912833108
360.7084453286808880.5831093426382230.291554671319112
370.6753947060822270.6492105878355460.324605293917773
380.6263349167561530.7473301664876940.373665083243847
390.5728974113800880.8542051772398240.427102588619912
400.5435509648210210.9128980703579580.456449035178979
410.5020915590297390.9958168819405220.497908440970261
420.7575288156648850.4849423686702310.242471184335115
430.9563070475383710.0873859049232570.0436929524616285
440.9666834209797180.06663315804056360.0333165790202818
450.9562902741612520.08741945167749670.0437097258387484
460.9612254468567140.07754910628657180.0387745531432859
470.9806509822552610.03869803548947740.0193490177447387
480.974216525457870.05156694908426220.0257834745421311
490.9821366416463710.03572671670725690.0178633583536284
500.9792101509228930.04157969815421410.0207898490771071
510.974466745752570.05106650849486110.0255332542474306
520.9975974613516140.0048050772967720.002402538648386
530.9965345544845240.006930891030952280.00346544551547614
540.9971213461018360.00575730779632820.0028786538981641
550.997104513935850.005790972128298580.00289548606414929
560.9959130703232510.008173859353497150.00408692967674857
570.9942292340735850.01154153185282980.00577076592641488
580.9935649807290860.01287003854182850.00643501927091424
590.995147676804760.009704646390480470.00485232319524023
600.9936622767108020.01267544657839690.00633772328919846
610.994486780541910.01102643891617780.00551321945808888
620.9950416877703480.009916624459304080.00495831222965204
630.9933549103728010.01329017925439750.00664508962719873
640.9937154061575680.01256918768486380.0062845938424319
650.9920741012968070.01585179740638680.00792589870319338
660.9912330134799510.01753397304009720.00876698652004858
670.9911936554924380.01761268901512420.00880634450756212
680.992408603297750.01518279340450070.00759139670225035
690.992622989007230.01475402198553770.00737701099276885
700.9900354594781920.01992908104361620.0099645405218081
710.9915123445940230.01697531081195310.00848765540597653
720.9887447120094480.02251057598110490.0112552879905524
730.9858755355293720.0282489289412560.014124464470628
740.9896839541107110.02063209177857820.0103160458892891
750.9860649847109670.02787003057806630.0139350152890332
760.9838140106574770.03237197868504520.0161859893425226
770.9787572305813240.04248553883735130.0212427694186757
780.971898413430230.05620317313953980.0281015865697699
790.9819288397198160.03614232056036870.0180711602801844
800.9811711890934850.03765762181302920.0188288109065146
810.9844656187665860.03106876246682740.0155343812334137
820.9855315805793760.0289368388412480.014468419420624
830.9805481128186120.03890377436277650.0194518871813882
840.9760251948548720.04794961029025640.0239748051451282
850.9936147428220520.01277051435589670.00638525717794837
860.9911861584938160.01762768301236880.00881384150618442
870.9879374134762950.02412517304741030.0120625865237051
880.9841687718519260.03166245629614730.0158312281480737
890.9802669954503850.03946600909922930.0197330045496147
900.9739334460187770.05213310796244690.0260665539812234
910.968947376731810.06210524653637970.0310526232681899
920.9814832067207420.03703358655851690.0185167932792585
930.9760770990135980.04784580197280390.0239229009864019
940.9728246090977620.05435078180447630.0271753909022381
950.965979035563560.0680419288728820.034020964436441
960.9575439971121530.08491200577569440.0424560028878472
970.9535973701117690.09280525977646260.0464026298882313
980.9410287167714980.1179425664570050.0589712832285023
990.9353320342401170.1293359315197650.0646679657598827
1000.9214983733308720.1570032533382570.0785016266691284
1010.9026602897059450.1946794205881110.0973397102940554
1020.8886871692377960.2226256615244080.111312830762204
1030.89189046225240.2162190754951990.108109537747600
1040.9289292049938920.1421415900122150.0710707950061076
1050.9254569164493070.1490861671013860.0745430835506932
1060.905625300271350.1887493994573010.0943746997286506
1070.885230909702820.2295381805943590.114769090297179
1080.8795482157603140.2409035684793710.120451784239686
1090.8769714482726470.2460571034547060.123028551727353
1100.8967147050313440.2065705899373120.103285294968656
1110.8888188319459750.2223623361080510.111181168054025
1120.9265296027254040.1469407945491920.073470397274596
1130.9048660085096630.1902679829806750.0951339914903373
1140.8827618407216510.2344763185566970.117238159278349
1150.8565786521910780.2868426956178440.143421347808922
1160.8473604826302370.3052790347395250.152639517369763
1170.8451600678784470.3096798642431050.154839932121553
1180.8462139050526980.3075721898946040.153786094947302
1190.8140406528364670.3719186943270660.185959347163533
1200.8513210199907520.2973579600184960.148678980009248
1210.8189905159203930.3620189681592150.181009484079607
1220.790452367248020.4190952655039610.209547632751980
1230.7825107808871970.4349784382256050.217489219112803
1240.7467063561374270.5065872877251460.253293643862573
1250.7341309093665210.5317381812669570.265869090633479
1260.7153981521943160.5692036956113680.284601847805684
1270.6572114164685910.6855771670628180.342788583531409
1280.6292789849081680.7414420301836650.370721015091832
1290.6362651289010090.7274697421979830.363734871098991
1300.6400845547008640.7198308905982720.359915445299136
1310.5945461467446810.8109077065106370.405453853255319
1320.5531033495610240.8937933008779530.446896650438976
1330.5436999016228740.9126001967542520.456300098377126
1340.471346782798360.942693565596720.52865321720164
1350.4143155955371650.828631191074330.585684404462835
1360.3937028356181140.7874056712362270.606297164381886
1370.3207904510305650.641580902061130.679209548969435
1380.4116151689132430.8232303378264860.588384831086757
1390.7713645714642730.4572708570714540.228635428535727
1400.7637751011990890.4724497976018230.236224898800911
1410.7096114088818370.5807771822363270.290388591118163
1420.6233492404007720.7533015191984560.376650759599228
1430.559951555234120.8800968895317610.440048444765880
1440.4346622858536390.8693245717072780.565337714146361
1450.6995806556278060.6008386887443870.300419344372194
1460.8492485876772470.3015028246455060.150751412322753


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level70.0510948905109489NOK
5% type I error level420.306569343065693NOK
10% type I error level550.401459854014599NOK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/103tfg1290276880.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/103tfg1290276880.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/1ea041290276880.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/1ea041290276880.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/2ea041290276880.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/2ea041290276880.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/371zp1290276880.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/371zp1290276880.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/471zp1290276880.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/471zp1290276880.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/571zp1290276880.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/571zp1290276880.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/60sys1290276880.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/60sys1290276880.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/7akfd1290276880.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/7akfd1290276880.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/8akfd1290276880.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/8akfd1290276880.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/9akfd1290276880.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t1290276818jlf3r91c8p1d0p0/9akfd1290276880.ps (open in new window)


 
Parameters (Session):
par1 = 1 ; par2 = Do not include Seasonal Dummies ; par3 = Linear Trend ;
 
Parameters (R input):
par1 = 1 ; par2 = Do not include Seasonal Dummies ; par3 = Linear Trend ;
 
R code (references can be found in the software module):
library(lattice)
library(lmtest)
n25 <- 25 #minimum number of obs. for Goldfeld-Quandt test
par1 <- as.numeric(par1)
x <- t(y)
k <- length(x[1,])
n <- length(x[,1])
x1 <- cbind(x[,par1], x[,1:k!=par1])
mycolnames <- c(colnames(x)[par1], colnames(x)[1:k!=par1])
colnames(x1) <- mycolnames #colnames(x)[par1]
x <- x1
if (par3 == 'First Differences'){
x2 <- array(0, dim=c(n-1,k), dimnames=list(1:(n-1), paste('(1-B)',colnames(x),sep='')))
for (i in 1:n-1) {
for (j in 1:k) {
x2[i,j] <- x[i+1,j] - x[i,j]
}
}
x <- x2
}
if (par2 == 'Include Monthly Dummies'){
x2 <- array(0, dim=c(n,11), dimnames=list(1:n, paste('M', seq(1:11), sep ='')))
for (i in 1:11){
x2[seq(i,n,12),i] <- 1
}
x <- cbind(x, x2)
}
if (par2 == 'Include Quarterly Dummies'){
x2 <- array(0, dim=c(n,3), dimnames=list(1:n, paste('Q', seq(1:3), sep ='')))
for (i in 1:3){
x2[seq(i,n,4),i] <- 1
}
x <- cbind(x, x2)
}
k <- length(x[1,])
if (par3 == 'Linear Trend'){
x <- cbind(x, c(1:n))
colnames(x)[k+1] <- 't'
}
x
k <- length(x[1,])
df <- as.data.frame(x)
(mylm <- lm(df))
(mysum <- summary(mylm))
if (n > n25) {
kp3 <- k + 3
nmkm3 <- n - k - 3
gqarr <- array(NA, dim=c(nmkm3-kp3+1,3))
numgqtests <- 0
numsignificant1 <- 0
numsignificant5 <- 0
numsignificant10 <- 0
for (mypoint in kp3:nmkm3) {
j <- 0
numgqtests <- numgqtests + 1
for (myalt in c('greater', 'two.sided', 'less')) {
j <- j + 1
gqarr[mypoint-kp3+1,j] <- gqtest(mylm, point=mypoint, alternative=myalt)$p.value
}
if (gqarr[mypoint-kp3+1,2] < 0.01) numsignificant1 <- numsignificant1 + 1
if (gqarr[mypoint-kp3+1,2] < 0.05) numsignificant5 <- numsignificant5 + 1
if (gqarr[mypoint-kp3+1,2] < 0.10) numsignificant10 <- numsignificant10 + 1
}
gqarr
}
bitmap(file='test0.png')
plot(x[,1], type='l', main='Actuals and Interpolation', ylab='value of Actuals and Interpolation (dots)', xlab='time or index')
points(x[,1]-mysum$resid)
grid()
dev.off()
bitmap(file='test1.png')
plot(mysum$resid, type='b', pch=19, main='Residuals', ylab='value of Residuals', xlab='time or index')
grid()
dev.off()
bitmap(file='test2.png')
hist(mysum$resid, main='Residual Histogram', xlab='values of Residuals')
grid()
dev.off()
bitmap(file='test3.png')
densityplot(~mysum$resid,col='black',main='Residual Density Plot', xlab='values of Residuals')
dev.off()
bitmap(file='test4.png')
qqnorm(mysum$resid, main='Residual Normal Q-Q Plot')
qqline(mysum$resid)
grid()
dev.off()
(myerror <- as.ts(mysum$resid))
bitmap(file='test5.png')
dum <- cbind(lag(myerror,k=1),myerror)
dum
dum1 <- dum[2:length(myerror),]
dum1
z <- as.data.frame(dum1)
z
plot(z,main=paste('Residual Lag plot, lowess, and regression line'), ylab='values of Residuals', xlab='lagged values of Residuals')
lines(lowess(z))
abline(lm(z))
grid()
dev.off()
bitmap(file='test6.png')
acf(mysum$resid, lag.max=length(mysum$resid)/2, main='Residual Autocorrelation Function')
grid()
dev.off()
bitmap(file='test7.png')
pacf(mysum$resid, lag.max=length(mysum$resid)/2, main='Residual Partial Autocorrelation Function')
grid()
dev.off()
bitmap(file='test8.png')
opar <- par(mfrow = c(2,2), oma = c(0, 0, 1.1, 0))
plot(mylm, las = 1, sub='Residual Diagnostics')
par(opar)
dev.off()
if (n > n25) {
bitmap(file='test9.png')
plot(kp3:nmkm3,gqarr[,2], main='Goldfeld-Quandt test',ylab='2-sided p-value',xlab='breakpoint')
grid()
dev.off()
}
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a, 'Multiple Linear Regression - Estimated Regression Equation', 1, TRUE)
a<-table.row.end(a)
myeq <- colnames(x)[1]
myeq <- paste(myeq, '[t] = ', sep='')
for (i in 1:k){
if (mysum$coefficients[i,1] > 0) myeq <- paste(myeq, '+', '')
myeq <- paste(myeq, mysum$coefficients[i,1], sep=' ')
if (rownames(mysum$coefficients)[i] != '(Intercept)') {
myeq <- paste(myeq, rownames(mysum$coefficients)[i], sep='')
if (rownames(mysum$coefficients)[i] != 't') myeq <- paste(myeq, '[t]', sep='')
}
}
myeq <- paste(myeq, ' + e[t]')
a<-table.row.start(a)
a<-table.element(a, myeq)
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable1.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,hyperlink('http://www.xycoon.com/ols1.htm','Multiple Linear Regression - Ordinary Least Squares',''), 6, TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Variable',header=TRUE)
a<-table.element(a,'Parameter',header=TRUE)
a<-table.element(a,'S.D.',header=TRUE)
a<-table.element(a,'T-STAT<br />H0: parameter = 0',header=TRUE)
a<-table.element(a,'2-tail p-value',header=TRUE)
a<-table.element(a,'1-tail p-value',header=TRUE)
a<-table.row.end(a)
for (i in 1:k){
a<-table.row.start(a)
a<-table.element(a,rownames(mysum$coefficients)[i],header=TRUE)
a<-table.element(a,mysum$coefficients[i,1])
a<-table.element(a, round(mysum$coefficients[i,2],6))
a<-table.element(a, round(mysum$coefficients[i,3],4))
a<-table.element(a, round(mysum$coefficients[i,4],6))
a<-table.element(a, round(mysum$coefficients[i,4]/2,6))
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable2.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a, 'Multiple Linear Regression - Regression Statistics', 2, TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'Multiple R',1,TRUE)
a<-table.element(a, sqrt(mysum$r.squared))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'R-squared',1,TRUE)
a<-table.element(a, mysum$r.squared)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'Adjusted R-squared',1,TRUE)
a<-table.element(a, mysum$adj.r.squared)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'F-TEST (value)',1,TRUE)
a<-table.element(a, mysum$fstatistic[1])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'F-TEST (DF numerator)',1,TRUE)
a<-table.element(a, mysum$fstatistic[2])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'F-TEST (DF denominator)',1,TRUE)
a<-table.element(a, mysum$fstatistic[3])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'p-value',1,TRUE)
a<-table.element(a, 1-pf(mysum$fstatistic[1],mysum$fstatistic[2],mysum$fstatistic[3]))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'Multiple Linear Regression - Residual Statistics', 2, TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'Residual Standard Deviation',1,TRUE)
a<-table.element(a, mysum$sigma)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'Sum Squared Residuals',1,TRUE)
a<-table.element(a, sum(myerror*myerror))
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable3.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a, 'Multiple Linear Regression - Actuals, Interpolation, and Residuals', 4, TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'Time or Index', 1, TRUE)
a<-table.element(a, 'Actuals', 1, TRUE)
a<-table.element(a, 'Interpolation<br />Forecast', 1, TRUE)
a<-table.element(a, 'Residuals<br />Prediction Error', 1, TRUE)
a<-table.row.end(a)
for (i in 1:n) {
a<-table.row.start(a)
a<-table.element(a,i, 1, TRUE)
a<-table.element(a,x[i])
a<-table.element(a,x[i]-mysum$resid[i])
a<-table.element(a,mysum$resid[i])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable4.tab')
if (n > n25) {
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Goldfeld-Quandt test for Heteroskedasticity',4,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'p-values',header=TRUE)
a<-table.element(a,'Alternative Hypothesis',3,header=TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'breakpoint index',header=TRUE)
a<-table.element(a,'greater',header=TRUE)
a<-table.element(a,'2-sided',header=TRUE)
a<-table.element(a,'less',header=TRUE)
a<-table.row.end(a)
for (mypoint in kp3:nmkm3) {
a<-table.row.start(a)
a<-table.element(a,mypoint,header=TRUE)
a<-table.element(a,gqarr[mypoint-kp3+1,1])
a<-table.element(a,gqarr[mypoint-kp3+1,2])
a<-table.element(a,gqarr[mypoint-kp3+1,3])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable5.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity',4,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Description',header=TRUE)
a<-table.element(a,'# significant tests',header=TRUE)
a<-table.element(a,'% significant tests',header=TRUE)
a<-table.element(a,'OK/NOK',header=TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'1% type I error level',header=TRUE)
a<-table.element(a,numsignificant1)
a<-table.element(a,numsignificant1/numgqtests)
if (numsignificant1/numgqtests < 0.01) dum <- 'OK' else dum <- 'NOK'
a<-table.element(a,dum)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'5% type I error level',header=TRUE)
a<-table.element(a,numsignificant5)
a<-table.element(a,numsignificant5/numgqtests)
if (numsignificant5/numgqtests < 0.05) dum <- 'OK' else dum <- 'NOK'
a<-table.element(a,dum)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'10% type I error level',header=TRUE)
a<-table.element(a,numsignificant10)
a<-table.element(a,numsignificant10/numgqtests)
if (numsignificant10/numgqtests < 0.1) dum <- 'OK' else dum <- 'NOK'
a<-table.element(a,dum)
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable6.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