Home » date » 2010 » Dec » 02 »

*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: Thu, 02 Dec 2010 19:29:24 +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/02/t1291318041sgph6rmslj1stt5.htm/, Retrieved Thu, 02 Dec 2010 20:27:32 +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/02/t1291318041sgph6rmslj1stt5.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 «
9 24 14 11 12 24 26 9 25 11 7 8 25 23 9 17 6 17 8 30 25 9 18 12 10 8 19 23 9 18 8 12 9 22 19 9 16 10 12 7 22 29 10 20 10 11 4 25 25 10 16 11 11 11 23 21 10 18 16 12 7 17 22 10 17 11 13 7 21 25 10 23 13 14 12 19 24 10 30 12 16 10 19 18 10 23 8 11 10 15 22 10 18 12 10 8 16 15 10 15 11 11 8 23 22 10 12 4 15 4 27 28 10 21 9 9 9 22 20 10 15 8 11 8 14 12 10 20 8 17 7 22 24 10 31 14 17 11 23 20 10 27 15 11 9 23 21 10 34 16 18 11 21 20 10 21 9 14 13 19 21 10 31 14 10 8 18 23 10 19 11 11 8 20 28 10 16 8 15 9 23 24 10 20 9 15 6 25 24 10 21 9 13 9 19 24 10 22 9 16 9 24 23 10 17 9 13 6 22 23 10 24 10 9 6 25 29 10 25 16 18 16 26 24 10 26 11 18 5 29 18 10 25 8 12 7 32 25 10 17 9 17 9 25 21 10 32 16 9 6 29 26 10 33 11 9 6 28 22 10 13 16 12 5 17 22 10 32 12 18 12 28 22 10 25 12 12 7 29 23 10 29 14 18 10 26 30 10 22 9 14 9 25 23 10 18 10 15 8 14 17 10 17 9 16 5 25 23 10 20 10 10 8 26 23 10 15 12 11 8 20 25 10 20 14 14 10 18 24 10 33 14 9 6 32 24 10 29 10 12 8 25 23 10 23 14 17 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 time10 seconds
R Server'Gwilym Jenkins' @ 72.249.127.135
R Framework
error message
The field 'Names of X columns' contains a hard return which cannot be interpreted.
Please, resubmit your request without hard returns in the 'Names of X columns'.


Multiple Linear Regression - Estimated Regression Equation
PersonalStandards[t] = + 21.0638481525474 -1.33226514613105month[t] + 0.331360289672297ConcernoverMistakes[t] -0.355719150002528Doubtsaboutactions[t] + 0.197976188475ParentalExpectations[t] + 0.00683989436930336ParentalCriticism[t] + 0.387508988376619`Organization `[t] -0.00225008961774506t + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)21.063848152547415.1650431.3890.1668860.083443
month-1.332265146131051.523395-0.87450.3832150.191607
ConcernoverMistakes0.3313602896722970.0557695.941600
Doubtsaboutactions-0.3557191500025280.107595-3.30610.0011820.000591
ParentalExpectations0.1979761884750.1020081.94080.0541470.027074
ParentalCriticism0.006839894369303360.1300450.05260.9581230.479062
`Organization `0.3875089883766190.0741045.22931e-060
t-0.002250089617745060.006424-0.35030.7266330.363316


Multiple Linear Regression - Regression Statistics
Multiple R0.609951812691802
R-squared0.372041213806015
Adjusted R-squared0.342930541598346
F-TEST (value)12.7802343811220
F-TEST (DF numerator)7
F-TEST (DF denominator)151
p-value7.8070883091641e-13
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation3.41825913153243
Sum Squared Residuals1764.35881903603


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
12424.3788411032984-0.378841103298412
22523.79331745685371.20668254314629
33025.67356066137354.32643933862652
41921.7075046653346-2.70750466533463
52221.98088749353980.0191125064601897
62224.4658886196-2.4658886196
72522.6882827174512.31171728254899
82319.50271562622023.4972843737798
91718.9427159653088-1.94271596530881
102121.7482044896363-0.748204489636267
111922.8673445099921-3.86734450999215
121923.5975542560347-4.59755425603468
131523.2588137498524-8.25881374985245
141617.2526667160132-1.25266671601317
152319.52259401449243.47740598550761
162724.10589621255802.89410378744205
172221.05356341396180.946436586038194
181416.7079113118806-2.70791131188055
192224.1935877676244-2.19358776762441
202324.1793095883575-1.17930958835751
212321.68187125883611.31812874116394
222124.6554281666088-3.65542816660885
231922.4448123844842-3.44481238448417
241823.9264831925835-5.92648319258348
252023.1505882072638-3.15058820726385
262322.47012339339960.529876606600380
272523.41707562936061.58292437063938
281923.3707531355731-4.37075313557309
292423.9062829126760.0937170873239819
302221.63278312616390.367216873836121
312525.1274850906094-0.127485090609402
322623.23492008873372.76507991126628
332922.94233327047896.05766672952114
343225.21426591772136.78573408227866
352521.65893913832983.34106086167018
362924.4702750947544.52972490524597
372825.02794509131472.97205490868526
381717.2069821292941-0.206982129294115
392826.15919053489521.84080946510476
402923.00287080325155.99712919674848
412627.5355633049122-1.53556330491216
422523.48107937069531.51892062930467
431419.6637513362319-5.66375133623185
442522.18837054257112.81162945742886
452621.65714472422574.34285527577433
462020.2596490514696-0.259649051469628
471821.4228614759953-3.4228614759953
483224.71105463226527.2889453677348
492525.0263393497554-0.0263393497553649
502521.82107399334623.17892600665381
512320.86775949306222.13224050693777
522122.117854032886-1.11785403288601
532023.9726413261168-3.97264132611681
541516.5457006606119-1.54570066061186
553026.68818285138343.31181714861657
562425.2744043336664-1.27440433366639
572624.23885255861381.76114744138620
582421.73596696696792.26403303303208
592221.35817540118730.641824598812666
601415.7380015387017-1.73800153870174
612422.16059181939991.83940818060007
622422.91801125545931.08198874454068
632423.29645432284270.703545677157297
642419.88291149793234.11708850206774
651918.47599654051490.524003459485107
663126.73048334635464.26951665364540
672226.5495294158872-4.54952941588722
682721.44866211201955.55133788798047
691917.65236012501161.34763987498842
702522.21816749900782.78183250099224
712024.9625665057518-4.96256650575181
722121.4159350820325-0.415935082032485
732727.4227120635285-0.422712063528469
742324.399868173257-1.39986817325701
752525.6847420541193-0.684742054119261
762022.2024072152892-2.20240721528923
772119.19800998218131.80199001781872
782222.3890673931533-0.389067393153251
792322.86289701780470.137102982195293
802524.06629454329020.933705456709783
812523.30499007466371.69500992533628
821723.6945505826395-6.69455058263948
831921.397982885467-2.39798288546698
842523.86987543710391.13012456289610
851922.2719093019712-3.27190930197122
862023.1090584144252-3.10905841442521
872622.45896674369643.54103325630361
882320.60779056407582.39220943592424
892724.33897230710742.66102769289259
901720.8386249075823-3.83862490758231
911723.2983394821097-6.29833948210969
921919.9942601881693-0.994260188169338
931719.6494842422993-2.64948424229929
942222.0232851008073-0.0232851008072933
952123.3306910343887-2.33069103438874
963228.5549779559483.44502204405199
972124.6245509755056-3.62455097550557
982124.2891262400522-3.28912624005225
991821.1740932510251-3.17409325102513
1001821.2400029865128-3.24000298651281
1012322.75376332900920.246236670990792
1021920.5465002291185-1.54650022911846
1032020.9652612427763-0.965261242776257
1042122.1891589001762-1.18915890017616
1052023.6300535236411-3.63005352364107
1061718.8311987042487-1.83119870424873
1071820.2285439329738-2.22854393297381
1081920.7040858341501-1.70408583415010
1092221.98244648577100.0175535142289650
1101518.7011860415034-3.7011860415034
1111418.7396316108277-4.7396316108277
1121826.471435033924-8.47143503392401
1132421.20695374939942.79304625060058
1143523.505122699618511.4948773003815
1152918.902119170756310.0978808292437
1162121.8443033733754-0.84430337337535
1172520.48490700602134.51509299397873
1182018.38139623239081.61860376760922
1192223.1087927659848-1.10879276598484
1201316.8342670146989-3.83426701469886
1212623.10386423904642.89613576095364
1221716.81655649956740.183443500432643
1232519.98387019687755.01612980312253
1242020.503457930182-0.503457930182017
1251917.96081147054241.03918852945757
1262122.5050016345108-1.50500163451080
1272220.88742363811361.11257636188644
1282422.47517128955521.52482871044484
1292122.7666882303897-1.76668823038966
1302625.32368843767530.676311562324669
1312420.44754175309153.55245824690852
1321620.1125993189920-4.11259931899195
1332322.16075858934670.839241410653308
1341820.61754812361-2.61754812361002
1351622.1819493252509-6.18194932525092
1362623.97932354214912.02067645785094
1371918.94000407312250.0599959268775127
1382116.79940608645384.20059391354616
1392121.9532949908417-0.953294990841725
1402218.36902928166053.63097071833953
1412319.65314522813973.34685477186026
1422924.65710237075934.3428976292407
1432119.15532902255131.84467097744868
1442119.76021113157231.23978886842772
1452321.71518261617221.28481738382783
1462722.84961876798194.15038123201806
1472525.2709551798013-0.270955179801295
1482120.80971397257630.190286027423701
1491016.9811157828466-6.98111578284664
1502022.4381017712208-2.43810177122084
1512622.30309976922003.69690023078004
1522423.50831867171680.49168132828322
1532931.5188532187234-2.51885321872343
1541918.94595077825720.0540492217428360
1552421.90535010773782.09464989226215
1561920.5742538575748-1.57425385757476
1572423.21862558125810.781374418741888
1582221.61449946949450.38550053050552
1591723.5852606802824-6.58526068028241


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
110.04722829156910360.09445658313820720.952771708430896
120.01423475691522680.02846951383045370.985765243084773
130.06428842912713740.1285768582542750.935711570872863
140.1235894120732940.2471788241465880.876410587926706
150.5752572659621580.8494854680756840.424742734037842
160.5190109299240040.9619781401519930.480989070075996
170.5652978009178070.8694043981643870.434702199082193
180.5237397530751650.952520493849670.476260246924835
190.4452285568544380.8904571137088760.554771443145562
200.5534619081530670.8930761836938650.446538091846933
210.5678230267072470.8643539465855060.432176973292753
220.5002354966453130.9995290067093730.499764503354687
230.4407071025270540.8814142050541070.559292897472946
240.4538287454854840.9076574909709680.546171254514516
250.4004178210394170.8008356420788350.599582178960583
260.3481241895193250.696248379038650.651875810480675
270.3140563948690640.6281127897381280.685943605130936
280.2969530275009170.5939060550018350.703046972499083
290.2589750824994860.5179501649989710.741024917500514
300.2079097080670840.4158194161341670.792090291932916
310.1776962699788220.3553925399576440.822303730021178
320.2182863609328520.4365727218657050.781713639067148
330.3035728642013540.6071457284027090.696427135798646
340.5199764599805460.9600470800389070.480023540019454
350.4703273849669140.9406547699338280.529672615033086
360.4771978783544280.9543957567088570.522802121645572
370.4390928171321650.878185634264330.560907182867835
380.468891311681290.937782623362580.53110868831871
390.4160642342853620.8321284685707250.583935765714638
400.4422206903109190.8844413806218380.557779309689081
410.4325939786516780.8651879573033570.567406021348322
420.3823175596910760.7646351193821510.617682440308924
430.5935699033805350.8128601932389310.406430096619465
440.5551396527803620.8897206944392760.444860347219638
450.5417994624942520.9164010750114960.458200537505748
460.5034853392285490.9930293215429020.496514660771451
470.5275450363200130.9449099273599740.472454963679987
480.604024642431790.791950715136420.39597535756821
490.5738966906887220.8522066186225560.426103309311278
500.5445301986974380.9109396026051240.455469801302562
510.5067728358781870.9864543282436250.493227164121813
520.4822346953744610.9644693907489230.517765304625539
530.5420383593664410.9159232812671190.457961640633559
540.519649944866880.960700110266240.48035005513312
550.5415717180010040.9168565639979910.458428281998996
560.517228263491510.965543473016980.48277173650849
570.4730438873092570.9460877746185150.526956112690742
580.4370269246820280.8740538493640550.562973075317972
590.3911213756227730.7822427512455470.608878624377227
600.3588281344382470.7176562688764940.641171865561753
610.321409074454370.642818148908740.67859092554563
620.2870476960039480.5740953920078960.712952303996052
630.2511225547303470.5022451094606950.748877445269653
640.2666858087665330.5333716175330670.733314191233467
650.2309913417720840.4619826835441690.769008658227916
660.2393880594829660.4787761189659330.760611940517034
670.3257877455370410.6515754910740820.674212254462959
680.3835115225924260.7670230451848520.616488477407574
690.3460888537582030.6921777075164060.653911146241797
700.3280864792706630.6561729585413260.671913520729337
710.4219110962239030.8438221924478050.578088903776097
720.3805870270403220.7611740540806450.619412972959678
730.3468214166331660.6936428332663330.653178583366834
740.319723265886660.639446531773320.68027673411334
750.2955486889979150.591097377995830.704451311002085
760.2742375205903480.5484750411806960.725762479409652
770.2554859001749830.5109718003499660.744514099825017
780.2220829921412310.4441659842824620.777917007858769
790.1914497904946970.3828995809893940.808550209505303
800.1691749821725430.3383499643450850.830825017827457
810.1513739146280400.3027478292560810.84862608537196
820.2370008817382350.474001763476470.762999118261765
830.2165460647169560.4330921294339110.783453935283044
840.1905245078201380.3810490156402760.809475492179862
850.1882707148200230.3765414296400450.811729285179977
860.1805176779551460.3610353559102930.819482322044854
870.1969384581087520.3938769162175050.803061541891248
880.1920268820690320.3840537641380640.807973117930968
890.1869700163354730.3739400326709470.813029983664527
900.1844095204967190.3688190409934370.815590479503281
910.2439201077217890.4878402154435780.756079892278211
920.2084096284178740.4168192568357470.791590371582126
930.1862498583588290.3724997167176580.813750141641171
940.1590043181548980.3180086363097970.840995681845102
950.1393464503664770.2786929007329530.860653549633523
960.1541916192471500.3083832384942990.84580838075285
970.1456983301142280.2913966602284560.854301669885772
980.1327881914340420.2655763828680840.867211808565958
990.1199699406733060.2399398813466120.880030059326694
1000.1097075361899590.2194150723799190.89029246381004
1010.08985471714296090.1797094342859220.91014528285704
1020.07245056457998330.1449011291599670.927549435420017
1030.05714926471001740.1142985294200350.942850735289983
1040.04502665378141750.0900533075628350.954973346218583
1050.04595455373318270.09190910746636540.954045446266817
1060.03685709577249710.07371419154499420.963142904227503
1070.03236092348534660.06472184697069320.967639076514653
1080.02962589002216290.05925178004432580.970374109977837
1090.02333455766980110.04666911533960220.976665442330199
1100.02422052390895340.04844104781790680.975779476091047
1110.03404209635046680.06808419270093370.965957903649533
1120.2349767701501450.4699535403002910.765023229849855
1130.2474928219535890.4949856439071780.752507178046411
1140.605998947366370.788002105267260.39400105263363
1150.8651558243698190.2696883512603630.134844175630181
1160.8336914448481460.3326171103037080.166308555151854
1170.8631133490050830.2737733019898340.136886650994917
1180.8344859960190120.3310280079619760.165514003980988
1190.8128580040534670.3742839918930650.187141995946533
1200.8690668927486690.2618662145026620.130933107251331
1210.841695273278780.3166094534424390.158304726721219
1220.8069660577661380.3860678844677230.193033942233862
1230.8151220725298960.3697558549402070.184877927470104
1240.7714562090075410.4570875819849170.228543790992459
1250.7367995567907310.5264008864185370.263200443209269
1260.6976967462481030.6046065075037930.302303253751897
1270.6488824923881050.702235015223790.351117507611895
1280.5962814058030190.8074371883939620.403718594196981
1290.5409657309752050.918068538049590.459034269024795
1300.4897388388030710.9794776776061420.510261161196929
1310.4612472291117730.9224944582235460.538752770888227
1320.4846459758603470.9692919517206940.515354024139653
1330.4196619159123520.8393238318247040.580338084087648
1340.3903036743217810.7806073486435620.609696325678219
1350.6910763844065840.6178472311868320.308923615593416
1360.6219947205760270.7560105588479460.378005279423973
1370.6079209324675130.7841581350649740.392079067532487
1380.552063011598180.8958739768036410.447936988401820
1390.5756137373693280.8487725252613450.424386262630673
1400.4988896162261120.9977792324522250.501110383773888
1410.436652908489570.873305816979140.56334709151043
1420.3937521849754310.7875043699508610.606247815024569
1430.4121081428384770.8242162856769540.587891857161523
1440.3524302428042630.7048604856085260.647569757195737
1450.2529538611569670.5059077223139340.747046138843033
1460.2160731281626150.4321462563252300.783926871837385
1470.1748569856346320.3497139712692630.825143014365368
1480.09686044374374780.1937208874874960.903139556256252


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level00OK
5% type I error level30.0217391304347826OK
10% type I error level100.072463768115942OK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/10svea1291318152.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/10svea1291318152.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/1lczy1291318152.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/1lczy1291318152.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/2lczy1291318152.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/2lczy1291318152.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/3lczy1291318152.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/3lczy1291318152.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/4emzj1291318152.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/4emzj1291318152.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/5emzj1291318152.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/5emzj1291318152.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/67vgm1291318152.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/67vgm1291318152.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/77vgm1291318152.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/77vgm1291318152.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/8h4x71291318152.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/8h4x71291318152.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/9h4x71291318152.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t1291318041sgph6rmslj1stt5/9h4x71291318152.ps (open in new window)


 
Parameters (Session):
par1 = 6 ; par2 = Do not include Seasonal Dummies ; par3 = Linear Trend ;
 
Parameters (R input):
par1 = 6 ; 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