Home » date » 2010 » Dec » 03 »

*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 23:03:05 +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/03/t1291330861d6ftcncdc4y99pj.htm/, Retrieved Fri, 03 Dec 2010 00:01:11 +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/03/t1291330861d6ftcncdc4y99pj.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 «
11 12 24 26 38 7 8 25 23 36 17 8 30 25 23 10 8 19 23 30 12 9 22 19 26 12 7 22 29 26 11 4 25 25 30 11 11 23 21 27 12 7 17 22 34 13 7 21 25 28 14 12 19 24 36 16 10 19 18 42 11 10 15 22 31 10 8 16 15 30 11 8 23 22 26 15 4 27 28 16 9 9 22 20 30 11 8 14 12 23 17 7 22 24 28 17 11 23 20 45 11 9 23 21 42 18 11 21 20 50 14 13 19 21 30 10 8 18 23 45 11 8 20 28 30 15 9 23 24 24 15 6 25 24 29 13 9 19 24 30 16 9 24 23 31 13 6 22 23 26 9 6 25 29 34 18 16 26 24 41 18 5 29 18 37 12 7 32 25 33 17 9 25 21 26 9 6 29 26 48 9 6 28 22 44 12 5 17 22 29 18 12 28 22 44 12 7 29 23 37 18 10 26 30 43 14 9 25 23 31 15 8 14 17 28 16 5 25 23 26 10 8 26 23 30 11 8 20 25 27 14 10 18 24 34 9 6 32 24 47 12 8 25 23 39 17 7 25 21 37 5 4 23 24 42 12 8 21 24 27 12 8 20 28 30 6 4 15 16 17 24 20 30 20 36 12 8 24 29 39 12 8 26 27 32 14 6 24 22 25 7 4 22 28 19 13 8 14 16 29 12 9 24 25 26 13 6 24 24 31 14 7 24 28 31 8 9 24 24 31 11 5 19 23 20 9 5 31 30 40 11 8 22 24 39 13 8 27 21 28 10 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'Gwilym Jenkins' @ 72.249.127.135


Multiple Linear Regression - Estimated Regression Equation
CM+D[t] = + 13.8648506940409 + 0.152805219548221ParentalExpectations[t] + 0.629365627171892ParentalCriticism[t] + 0.449660665114335PersonalStandards[t] + 0.0677807458976412Organization[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)13.86485069404094.2441673.26680.0013410.000671
ParentalExpectations0.1528052195482210.1986790.76910.4430080.221504
ParentalCriticism0.6293656271718920.2476352.54150.0120260.006013
PersonalStandards0.4496606651143350.1430423.14360.0020030.001001
Organization0.06778074589764120.1531240.44270.6586370.329319


Multiple Linear Regression - Regression Statistics
Multiple R0.419463868754593
R-squared0.175949937190571
Adjusted R-squared0.154546039455261
F-TEST (value)8.22046243008849
F-TEST (DF numerator)4
F-TEST (DF denominator)154
p-value4.91173108119192e-06
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation6.71059243516357
Sum Squared Residuals6934.93582795469


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
13835.65225099121672.34774900878331
23632.76988603175773.23011396824229
32336.6818030446069-13.6818030446069
43030.5303376997164-0.530337699716388
52632.5431727777371-6.54317277773713
62631.9622489823698-5.96224898236977
73030.9992058930583-0.99920589305831
82734.2343209694423-7.23432096944232
93429.23948043551464.7605195644854
102831.3942705532131-3.39427055321309
113633.72680183249452.27319816750554
124232.36699654186139.63300345813873
133130.07545076725340.92454923274661
143028.63910973719221.36089026280777
152632.4140048338243-6.41400483382428
161632.7130903391728-16.7130903391728
173032.1525378649901-2.15253786499011
182327.6892513888189-4.68925138881886
192832.3873713506227-4.38737135062267
204535.0833715408349.916628459166
214232.97558971509859.02441028490147
225034.336855430153615.6631445698464
233034.1528252219734-4.15282522197343
244530.080677034602014.9193229653980
253031.4717073138671-1.47170731386713
262433.7901528309843-9.79015283098434
272932.8013772796973-3.80137727969734
283031.6858997314306-1.68589973143056
293134.3248379697493-3.32483796974926
302631.0790040993603-5.07900409936025
313432.22344969189621.77655030810378
324140.00310987517530.996890124824745
333734.02238549624162.9776145037584
343336.1877326499226-3.18773264992255
352634.7917423626165-8.79174236261653
364833.818750114660614.1812498853394
374433.097966465955710.9020335340443
382927.98074918117081.01925081882918
394438.24940720492115.75059279507892
403734.70318916278432.29681083721574
414336.63360058752986.36639941247025
423134.4688881957671-3.46888819576715
432828.6393759965000-0.639375996499952
442632.257036126176-6.25703612617603
453033.6779623555167-3.67796235551671
462731.2683650761742-4.2683650761742
473432.01840991303631.98159008696366
484735.032170618208411.9678293817916
493933.53391212949885.46608787050118
503733.53301110827283.46698889172725
514229.115272499642712.8847275003573
522731.8030502149391-4.80305021493912
533031.6245125334153-1.62451253341535
541725.1285464310951-8.12854643109508
553644.9649233780189-8.96492337801892
563933.49093593977035.50906406022967
573234.2546957782037-2.25469577820372
582532.0633499032395-7.0633499032395
591929.2423452572153-10.2423452572153
602928.26598481150590.734015188494133
612633.8491785833517-7.84917858335166
623132.0461061754866-1.04610617548656
633133.0994000057972-2.09940000579724
643133.1701769592611-2.17017695926113
652028.7950460377489-8.79504603774891
664034.3598288013085.64017119869203
673932.09990566050526.90009433949477
682834.4504771874804-6.45047718748042
692229.4071679371679-7.40716793716786
703133.5166684017459-2.51666840174588
713630.58846243085765.41153756914239
722830.6474881832249-2.64748818322492
733935.7243569832373.27564301676303
744435.43951899807528.56048100192485
753532.8691580255952.13084197440502
763331.15004731213191.84995268786814
772730.7649049260412-3.7649049260412
783333.1876869463218-0.187686946321788
793132.7356648355595-1.73566483555955
803932.36020534880566.63979465119439
813735.21657158698141.78342841301861
822429.9871638267288-5.98716382672884
833330.92097261246342.07902738753661
842835.4716450079331-7.47164500793313
853728.60775336269488.39224663730519
863231.33524480084580.66475519915422
873132.0104514394469-1.01045143944690
882932.5828596160113-3.58285961601133
894038.75286735505411.24713264494592
902929.1716996896170-0.171699689616964
914030.31001799357829.68998200642178
921529.0337767521738-14.0337767521738
932727.5901142684238-0.590114268423799
943231.18127230076380.81872769923623
952833.1123184874276-5.1123184874276
964140.77758850761360.222411492386357
974732.805807027105114.1941929728949
984235.03400180322316.96599819677691
992829.6213603547313-1.6213603547313
1003230.26796970965611.73203029034387
1013334.2161762204633-1.21617622046331
1022229.4416553926737-7.44165539267374
1032933.139511373825-4.13951137382499
1042633.3846356361323-7.38463563613228
1053732.79821931410864.20178068589145
1063927.353478740339111.6465212596609
1072929.0446269320443-0.0446269320442908
1083331.70523864552371.29476135447632
1093934.39588118252094.60411881747913
1103127.64301273221643.3569872677836
1112127.6871562024787-6.68715620247868
1123633.58275160647662.41724839352343
1132934.3105904495626-5.31059044956257
1143240.4287625040613-8.42876250406132
1151536.6094307932789-21.6094307932789
1162430.0677585529717-6.06775855297167
1172533.6879115141612-8.68791151416115
1182829.2973389073481-1.29733890734813
1193933.340492165875.65950783412999
1203124.33149330226996.66850669773007
1214030.63430344228689.36569655771316
1222528.8327959601288-3.83279596012876
1233635.45649646652040.543503533479632
1242329.2456077240893-6.24560772408931
1253929.73092312524339.26907687475669
1263132.4992955667826-1.49929556678259
1272329.4296379322694-6.42963793226944
1283133.1347884825292-2.13478848252918
1292832.8735877730027-4.87358777300274
1304733.966329066860213.0336709331398
1313334.7862498359602-1.78624983596017
1322529.3514046516745-4.35140465167452
1332630.7970309358992-4.79703093589917
1342427.4104093063662-3.41040930636624
1353129.48696614346981.51303385653020
1363936.39696505944512.60303494055493
1373129.37387464677611.6261253532239
1383031.8396328567852-1.83963285678518
1392532.432415842111-7.43241584211101
1403534.78951230283410.210487697165861
1414432.195514054718611.8044859452814
1424236.98192095704705.01807904295304
1433840.2401699330135-2.2401699330135
1443629.15092723568236.84907276431766
1453435.2189330326293-1.21893303262929
1464533.089477731733111.9105222682669
1474034.65618087082135.34381912917875
1482930.7497563846284-1.74975638462844
1492526.7405603209793-1.74056032097927
1503032.6466082596744-2.64660825967445
1512734.3923524563392-7.39235245633918
1524433.76325308847510.236746911525
1534936.485120614104112.5148793858959
1543129.13723911869141.86276088130859
1553137.2501791189368-6.25017911893679
1562629.5944606122220-3.59446061222196
1574232.99922699073399.0007730092661
1583533.83429630124661.16570369875338
1594735.837846125103911.1621538748961


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
80.1819107881334240.3638215762668470.818089211866576
90.300726071429640.601452142859280.69927392857036
100.1786662716214470.3573325432428940.821333728378553
110.1530773443199540.3061546886399080.846922655680046
120.3916307538156550.783261507631310.608369246184346
130.3469258886208690.6938517772417380.653074111379131
140.2843451758118550.5686903516237090.715654824188145
150.2377808998784090.4755617997568180.762219100121591
160.2750491430125960.5500982860251910.724950856987404
170.2078609420852140.4157218841704270.792139057914786
180.2472087450907770.4944174901815550.752791254909223
190.1909512679152600.3819025358305190.80904873208474
200.3581885743042070.7163771486084140.641811425695793
210.4829025563545820.9658051127091630.517097443645418
220.6676675137176280.6646649725647430.332332486282371
230.7378860611743690.5242278776512630.262113938825631
240.8931325375340670.2137349249318660.106867462465933
250.8599759515092630.2800480969814740.140024048490737
260.8795589404747990.2408821190504020.120441059525201
270.850480177241930.2990396455161400.149519822758070
280.8160152264819980.3679695470360040.183984773518002
290.7755113448640490.4489773102719020.224488655135951
300.7355762761797860.5288474476404280.264423723820214
310.732642093721680.5347158125566390.267357906278319
320.6830751181889590.6338497636220820.316924881811041
330.7101528453101680.5796943093796640.289847154689832
340.670012980427050.65997403914590.32998701957295
350.6897277175443810.6205445649112370.310272282455619
360.8797093025634280.2405813948731450.120290697436572
370.909913214299750.1801735714004990.0900867857002493
380.8882932661510350.2234134676979290.111706733848965
390.8813294587369660.2373410825260690.118670541263034
400.8548350117272480.2903299765455040.145164988272752
410.8724648553606530.2550702892786940.127535144639347
420.8512957162638710.2974085674722570.148704283736129
430.8187375877718210.3625248244563580.181262412228179
440.8035924924564680.3928150150870650.196407507543532
450.7822098685743740.4355802628512510.217790131425626
460.7561326124157680.4877347751684650.243867387584232
470.718536342552180.562927314895640.28146365744782
480.7866181822692050.4267636354615890.213381817730795
490.7696042399685270.4607915200629470.230395760031473
500.7465733908966070.5068532182067860.253426609103393
510.8255372448351570.3489255103296870.174462755164843
520.8089210304537340.3821579390925310.191078969546266
530.7746793161495860.4506413677008290.225320683850414
540.8010722201041040.3978555597917910.198927779895896
550.8360727744536770.3278544510926450.163927225546323
560.8259950313520890.3480099372958230.174004968647912
570.7978384021171730.4043231957656540.202161597882827
580.7975178348827950.4049643302344110.202482165117205
590.8410589494445410.3178821011109180.158941050555459
600.8112225623539940.3775548752920120.188777437646006
610.8229207241922920.3541585516154170.177079275807708
620.7917285666956640.4165428666086730.208271433304336
630.7609496983159420.4781006033681160.239050301684058
640.7334421194104130.5331157611791740.266557880589587
650.7557929832210770.4884140335578460.244207016778923
660.742549935811210.5149001283775810.257450064188791
670.7452333378408630.5095333243182730.254766662159137
680.7449425036885270.5101149926229460.255057496311473
690.7501295948245680.4997408103508650.249870405175432
700.7175844952842460.5648310094315070.282415504715754
710.7063588884871680.5872822230256630.293641111512832
720.6721167527227410.6557664945545170.327883247277259
730.6408978343943990.7182043312112030.359102165605601
740.6732761117913390.6534477764173230.326723888208661
750.6390300624786160.7219398750427680.360969937521384
760.598183348589280.803633302821440.40181665141072
770.5688978828111270.8622042343777460.431102117188873
780.5232626920869090.9534746158261820.476737307913091
790.4796068667570760.9592137335141510.520393133242924
800.4765870637591440.9531741275182880.523412936240856
810.4337251086816610.8674502173633220.566274891318339
820.422202588157040.844405176314080.57779741184296
830.3825647928806960.7651295857613910.617435207119304
840.3956446623743290.7912893247486580.604355337625671
850.4225692795133210.8451385590266420.577430720486679
860.3845146234269350.7690292468538710.615485376573065
870.3422625115652820.6845250231305640.657737488434718
880.3120787189501880.6241574379003750.687921281049813
890.2742052105095220.5484104210190440.725794789490478
900.2373218942611510.4746437885223020.762678105738849
910.2766256915408110.5532513830816210.723374308459189
920.4212920235274850.842584047054970.578707976472515
930.3775683982885610.7551367965771220.622431601711439
940.3354295473907740.6708590947815470.664570452609226
950.3187873126171550.637574625234310.681212687382845
960.2787662744743980.5575325489487960.721233725525602
970.4148605500058620.8297211000117230.585139449994138
980.4140763723958590.8281527447917180.585923627604141
990.3720844813349620.7441689626699230.627915518665038
1000.329487428953620.658974857907240.67051257104638
1010.2887506278931680.5775012557863360.711249372106832
1020.3050778667902970.6101557335805930.694922133209704
1030.2837437446348420.5674874892696840.716256255365158
1040.2964154440578420.5928308881156840.703584555942158
1050.2699539593576650.5399079187153290.730046040642335
1060.3406619544406990.6813239088813980.659338045559301
1070.2967128803257680.5934257606515350.703287119674232
1080.2581052164479260.5162104328958530.741894783552074
1090.2353128099930430.4706256199860860.764687190006957
1100.2047832051391480.4095664102782960.795216794860852
1110.2081699994785060.4163399989570130.791830000521494
1120.1765065718810850.3530131437621700.823493428118915
1130.1597583351532550.3195166703065090.840241664846745
1140.1798456046289850.3596912092579710.820154395371015
1150.664453329623610.6710933407527790.335546670376389
1160.6649519677796730.6700960644406540.335048032220327
1170.7386788841392860.5226422317214270.261321115860714
1180.6984405101097370.6031189797805270.301559489890263
1190.676095098180170.647809803639660.32390490181983
1200.7053575292605430.5892849414789150.294642470739457
1210.7088403810205820.5823192379588350.291159618979418
1220.6673362708843860.6653274582312280.332663729115614
1230.6186347120723320.7627305758553360.381365287927668
1240.6236236327752410.7527527344495180.376376367224759
1250.6752541377546070.6494917244907860.324745862245393
1260.6255431721941530.7489136556116930.374456827805847
1270.6509681364965220.6980637270069560.349031863503478
1280.6196845241530430.7606309516939140.380315475846957
1290.6129430938295830.7741138123408350.387056906170417
1300.6885642906907870.6228714186184250.311435709309213
1310.6466066750714030.7067866498571940.353393324928597
1320.6027861051070450.794427789785910.397213894892955
1330.6271191163493460.7457617673013070.372880883650654
1340.6023580945372230.7952838109255540.397641905462777
1350.5341304521790110.9317390956419790.465869547820989
1360.4693336386783770.9386672773567530.530666361321623
1370.3987071770692520.7974143541385040.601292822930748
1380.3422387803724570.6844775607449150.657761219627543
1390.4313602187865540.8627204375731080.568639781213446
1400.3568538810885790.7137077621771580.643146118911421
1410.5503236102469850.899352779506030.449676389753015
1420.4808660575719060.9617321151438120.519133942428094
1430.427844065156670.855688130313340.57215593484333
1440.3572784184378180.7145568368756370.642721581562182
1450.3090945357864570.6181890715729130.690905464213543
1460.4196224186317410.8392448372634820.580377581368259
1470.3729541771661560.7459083543323130.627045822833844
1480.2723963999569190.5447927999138380.727603600043081
1490.193160735375720.386321470751440.80683926462428
1500.1420505509087750.2841011018175500.857949449091225
1510.1108886428789240.2217772857578480.889111357121076


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


http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/1b3cb1291330973.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/1b3cb1291330973.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/2b3cb1291330973.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/2b3cb1291330973.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/3lube1291330973.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/3lube1291330973.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/4lube1291330973.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/4lube1291330973.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/5lube1291330973.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/5lube1291330973.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/6w4az1291330973.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/6w4az1291330973.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/77ds21291330973.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/77ds21291330973.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/87ds21291330973.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/87ds21291330973.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/97ds21291330973.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/03/t1291330861d6ftcncdc4y99pj/97ds21291330973.ps (open in new window)


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