Home » date » 2010 » Dec » 15 »

*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: Wed, 15 Dec 2010 02:56:11 +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/15/t1292382697sfztwce3yyuk9nh.htm/, Retrieved Wed, 15 Dec 2010 04:11:37 +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/15/t1292382697sfztwce3yyuk9nh.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 12 12 8 13 5 15 10 12 16 6 12 9 7 12 6 10 10 10 11 5 12 12 7 12 3 15 13 16 18 8 9 12 11 11 4 12 12 14 14 4 11 6 6 9 4 11 5 16 14 6 11 12 11 12 6 15 11 16 11 5 7 14 12 12 4 11 14 7 13 6 11 12 13 11 4 10 12 11 12 6 14 11 15 16 6 10 11 7 9 4 6 7 9 11 4 11 9 7 13 2 15 11 14 15 7 11 11 15 10 5 12 12 7 11 4 14 12 15 13 6 15 11 17 16 6 9 11 15 15 7 13 8 14 14 5 13 9 14 14 6 16 12 8 14 4 13 10 8 8 4 12 10 14 13 7 14 12 14 15 7 11 8 8 13 4 9 12 11 11 4 16 11 16 15 6 12 12 10 15 6 10 7 8 9 5 13 11 14 13 6 16 11 16 16 7 14 12 13 13 6 15 9 5 11 3 5 15 8 12 3 8 11 10 12 4 11 11 8 12 6 16 11 13 14 7 17 11 15 14 5 9 15 6 8 4 9 11 12 13 5 13 12 16 16 6 10 12 5 13 6 6 9 15 11 6 12 12 12 14 5 8 12 8 13 4 14 13 13 13 5 12 11 14 13 5 11 9 12 12 4 16 9 16 16 6 8 11 10 15 2 15 11 15 15 8 7 12 8 12 3 16 12 16 14 6 14 9 19 12 6 16 11 14 15 6 9 9 6 12 5 14 12 13 13 5 11 12 15 12 6 13 12 7 12 5 15 12 13 13 6 5 14 4 5 2 15 11 14 13 5 13 12 13 13 5 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 time6 seconds
R Server'Sir Ronald Aylmer Fisher' @ 193.190.124.24


Multiple Linear Regression - Estimated Regression Equation
Popularity[t] = + 0.311900251104236 + 0.0962538968572747FindingFriends[t] + 0.243370280084764KnowingPeople[t] + 0.351380635996807Liked[t] + 0.627591839447788Celebrity[t] -0.000729053587325965t + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)0.3119002511042361.4303540.21810.827680.41384
FindingFriends0.09625389685727470.0966810.99560.3210550.160528
KnowingPeople0.2433702800847640.0616163.94980.000126e-05
Liked0.3513806359968070.0976573.59810.0004350.000217
Celebrity0.6275918394477880.1565554.00889.6e-054.8e-05
t-0.0007290535873259650.003824-0.19070.849050.424525


Multiple Linear Regression - Regression Statistics
Multiple R0.706626862823286
R-squared0.499321523263479
Adjusted R-squared0.482632240705595
F-TEST (value)29.918693121269
F-TEST (DF numerator)5
F-TEST (DF denominator)150
p-value0
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation2.11226554360225
Sum Squared Residuals669.249859003394


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
11311.42037956415001.57962043584995
21211.11835861209240.881641387907582
31513.58033663256781.41966336743219
41210.86097973771221.13902026228784
51010.7076429457918-0.707642945791806
6129.265507802765972.73449219723403
71516.7976081800186-1.79760818001857
8910.5137420193814-1.51374201938135
91212.2972657140387-0.297265714038741
10118.015147858645622.98485214135438
111113.3639545679283-2.36395456792827
121112.1173901199244-1.11739011992443
131512.25828609445912.74171390554094
14711.2966264076535-4.29662640765352
151111.6856102685348-0.685610268534755
161110.99465015085230.00534984914772409
171012.1137448519878-2.11374485198780
181414.3957655658695-0.395765565869486
19108.733226140730821.26677385926918
2069.53698333187754-3.53698333187754
21118.689599104933272.31040089506673
221514.42569027488640.574309725113601
231111.6562446425042-0.656244642504229
24129.528596041645082.47140395835492
251413.43277417962510.56722582037494
261514.87667369734040.123326302659594
27914.6654152870345-5.66541528703453
281312.52598994789820.474010052101763
291313.2491066306160-0.249106630615974
301610.82173390819635.17826609180369
31138.52021324491364.4797867550864
321213.6193845701623-1.61938457016225
331414.5139245822831-0.513924582283089
341110.08242147042110.917578529578898
35910.4940575725236-1.49405757252355
361614.27463224538561.72536775461442
371212.9099354081469-0.90993540814694
38109.205320654675080.794679345324915
391313.0829432524605-0.0829432524604571
401615.25068850648090.749311493519134
411412.93436876205831.06563123794168
42158.112378986884076.88762101311593
4359.7706647906915-4.7706647906915
44810.4992525492924-2.49925254929239
451111.2669666144311-0.26696661443111
461613.8134420727092.18655792729099
471713.04426990039563.95573009960437
4898.50234825804590.4976517419541
49911.9613203169699-2.96132031696988
501314.7120600280171-1.71206002801709
511010.9801159855069-0.980115985506942
52612.4215667702018-6.42156677020182
531212.4060386354747-0.406038635474659
54810.4528559861037-2.45285598610368
551412.39282406924521.60717593075476
561212.4429575020281-0.442957502028128
571110.78400761911210.215992380887871
581614.41746590874671.58253409125334
59810.2872749745773-2.28727497457734
601515.2689483581006-0.268948358100565
6179.4687801355478-2.46878013554781
621614.00055011297561.99944988702443
631413.73840893707710.261591062922901
641613.76747818477092.23252181522908
6599.94554534935272-0.945545349352724
661412.28855058292741.71144941707262
671113.0507732929606-2.05077329296056
681310.47549015924732.52450984075266
691512.91395526161322.08604473838681
7055.59398903521193-0.59398903521193
711512.43202169821822.56797830178176
721312.28417626140340.715823738596577
731112.0518333867861-1.0518333867861
741113.9816794366049-2.9816794366049
751212.4737028662899-0.473702866289919
761213.3955924466714-1.39559244667143
771212.2687745344120-0.268774534412025
781211.89478635245040.105213647549632
791410.78601028241733.21398971758266
8067.98921508177449-1.98921508177449
8179.8384206231643-2.83842062316431
821411.97557354783752.02442645216250
831413.86163652252380.13836347747623
841011.2447986284746-1.24479862847463
85138.721172009197694.27882799080231
861212.4030643314044-0.403064331404351
8799.27840141287423-0.278401412874230
881212.0072626315439-0.00726263154391849
891615.00443552398330.995564476016653
901010.2223458041906-0.222345804190629
911413.12569325357090.87430674642913
921013.5036944042410-3.50369440424103
931615.30830256320990.691697436790135
941513.43333196846981.56666803153022
951211.33303293587130.666967064128684
96109.719474463442380.280525536557623
97810.2219397561188-2.22193975611881
9888.59192749759564-0.591927497595641
991112.8256077791949-1.8256077791949
1001312.40461404023660.595385959763445
1011615.44958651773870.550413482261253
1021614.70699016484241.29300983515764
1031415.8120595336817-1.81205953368175
104118.866192833320752.13380716667925
10546.94035975221045-2.94035975221045
1061414.5624489223711-0.562448922371105
107910.3242273530674-1.32422735306736
1081415.2339537859089-1.23395378590892
109810.4307796018048-2.43077960180475
110810.8768910530054-2.87689105300543
1111112.1712457336952-1.17124573369520
1121213.6119227695464-1.61192276954639
1131111.4216552232623-0.421655223262261
1141413.58390912217710.416090877822867
1151514.31878226394960.681217736050363
1161613.37818676223322.62181323776684
1171613.47371160550312.52628839449689
1181112.7155221434008-1.71552214340081
1191413.71562377841320.284376221586775
1201410.93058503682513.06941496317486
1211211.37749051609190.622509483908102
1221412.53019988943731.46980011056266
123810.1982870358089-2.19828703580887
1241313.8082324073339-0.80823240733387
1251613.71124945688932.28875054311073
1261210.89259604309131.10740395690872
1271615.42436602051900.575633979480958
1281213.3576816601305-1.35768166013048
1291111.4788744152393-0.478874415239258
13046.36326604189702-2.36326604189702
1311615.42144980616970.578550193830262
1321512.52840070866962.47159929133039
1331011.4494026606953-1.44940266069535
1341313.1788413871184-0.178841387118360
1351513.21721836084651.78278163915352
1361210.63644387202771.36355612797228
1371413.60624691698410.393753083015917
138710.6294944097475-3.62949440974753
1391914.05242334266354.94757665733649
1401212.6368437398323-0.636843739832278
1411212.2401366678272-0.240136667827161
1421313.4554852658200-0.455485265819964
1431512.90233380533072.09766619466933
14488.22180947772168-0.221809477721677
1451210.87325266982651.12674733017345
1461010.7637395114835-0.763739511483486
147811.3640264779270-3.36402647792696
1481014.3346235509494-4.3346235509494
1491513.84086855402091.15913144597906
1501614.56947659184421.43052340815579
1511313.1421405299582-0.142140529958209
1521615.02191812147290.978081878527131
153910.1764154281891-1.17641542818909
1541413.11886890488480.88113109511522
1551412.64699240033381.35300759966616
1561210.10854642069471.89145357930532


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
90.02712889731447260.05425779462894510.972871102685527
100.02373201601878250.0474640320375650.976267983981218
110.05007464839441310.1001492967888260.949925351605587
120.03368950223637980.06737900447275950.96631049776362
130.437716993543970.875433987087940.56228300645603
140.6316563046021750.736687390795650.368343695397825
150.5644064685689570.8711870628620850.435593531431043
160.4898538966176390.9797077932352790.510146103382361
170.4071749612637090.8143499225274180.592825038736291
180.3752283278886790.7504566557773570.624771672111321
190.3234242980174950.646848596034990.676575701982505
200.4507550203133370.9015100406266740.549244979686663
210.4552502339366930.9105004678733860.544749766063307
220.4980670159275540.9961340318551080.501932984072446
230.4363715860395880.8727431720791760.563628413960412
240.4545691245820360.9091382491640720.545430875417964
250.4303559148050240.8607118296100480.569644085194976
260.3761378032845510.7522756065691020.623862196715449
270.6071415742230360.7857168515539280.392858425776964
280.5582137086585030.8835725826829930.441786291341497
290.5018775261643080.9962449476713840.498122473835692
300.6806149782735140.6387700434529720.319385021726486
310.7848748240737090.4302503518525820.215125175926291
320.7475318694581150.5049362610837710.252468130541885
330.6991622362990250.601675527401950.300837763700975
340.6635366045134880.6729267909730240.336463395486512
350.6696571087682650.660685782463470.330342891231735
360.6770310108730860.6459379782538280.322968989126914
370.6441962705471480.7116074589057030.355803729452852
380.5944451175840880.8111097648318250.405554882415912
390.540247519348870.919504961302260.45975248065113
400.5109253844648880.9781492310702240.489074615535112
410.4702767250187360.9405534500374720.529723274981264
420.735932527574330.5281349448513390.264067472425670
430.9498969266616530.1002061466766950.0501030733383473
440.9618637636256220.07627247274875580.0381362363743779
450.9504794200293230.0990411599413530.0495205799706765
460.956121562441370.08775687511725810.0438784375586291
470.9780050416388570.04398991672228540.0219949583611427
480.9709778518565920.05804429628681550.0290221481434078
490.979869971208340.04026005758331850.0201300287916592
500.9768820692080460.04623586158390730.0231179307919536
510.9721887475291550.05562250494169050.0278112524708453
520.9973138774368590.005372245126281980.00268612256314099
530.9961461927906140.00770761441877220.0038538072093861
540.996909857342270.006180285315461410.00309014265773071
550.9967891747919470.006421650416106410.00321082520805321
560.995474626740240.009050746519520080.00452537325976004
570.9936557628918140.01268847421637140.00634423710818569
580.9929661867861520.01406762642769510.00703381321384755
590.9945914439920650.01081711201586960.0054085560079348
600.9929280109472360.0141439781055270.0070719890527635
610.9937939122155120.01241217556897650.00620608778448827
620.9944798961762630.01104020764747420.00552010382373709
630.9926749290423060.01465014191538780.00732507095769392
640.9931953130628560.01360937387428710.00680468693714357
650.991362425086320.01727514982736090.00863757491368045
660.9906063599090930.01878728018181460.00939364009090729
670.9905151144312320.01896977113753710.00948488556876853
680.9920123112137370.01597537757252570.00798768878626283
690.9921592761377870.01568144772442580.0078407238622129
700.9894755957305780.02104880853884450.0105244042694222
710.991146581644350.01770683671129960.00885341835564978
720.9883631806332680.02327363873346350.0116368193667318
730.9853943801996670.02921123960066680.0146056198003334
740.989423409464030.02115318107193930.0105765905359696
750.9857333151283550.02853336974329070.0142666848716453
760.9832710566093790.03345788678124280.0167289433906214
770.9779924896479920.04401502070401560.0220075103520078
780.970991389696050.05801722060790110.0290086103039506
790.9817652488847430.03646950223051470.0182347511152574
800.9808862149799350.03822757004013040.0191137850200652
810.9840648936251040.03187021274979300.0159351063748965
820.9850011894587430.02999762108251430.0149988105412572
830.9799193938455660.04016121230886830.0200806061544342
840.975301719085280.04939656182943940.0246982809147197
850.9935872347096980.01282553058060370.00641276529030183
860.9911351101146010.01772977977079730.00886488988539866
870.988020449050020.02395910189995890.0119795509499794
880.9843528530299830.03129429394003310.0156471469700165
890.9805943928199380.03881121436012480.0194056071800624
900.9745712936747530.05085741265049320.0254287063252466
910.9701027085906160.05979458281876730.0298972914093837
920.9817541493793390.03649170124132240.0182458506206612
930.9764739227590290.04705215448194210.0235260772409710
940.9736869171707830.05262616565843470.0263130828292174
950.967493542405080.06501291518984030.0325064575949201
960.9599840934920060.08003181301598710.0400159065079936
970.9562319242184290.08753615156314230.0437680757815712
980.9446532935513370.1106934128973260.0553467064486632
990.9395514308045070.1208971383909870.0604485691954934
1000.9271862288156380.1456275423687250.0728137711843623
1010.909654431578330.180691136843340.09034556842167
1020.8974776614051540.2050446771896910.102522338594846
1030.899061654614460.2018766907710790.100938345385540
1040.9348483751247250.1303032497505490.0651516248752746
1050.9313246359837920.1373507280324160.0686753640162081
1060.9125493563558660.1749012872882690.0874506436441344
1070.8930246516619960.2139506966760080.106975348338004
1080.8843853500420880.2312292999158230.115614649957912
1090.8804341743548570.2391316512902850.119565825645142
1100.9022293013752040.1955413972495920.097770698624796
1110.8930334521576350.2139330956847300.106966547842365
1120.9279799681029920.1440400637940160.0720200318970082
1130.906831134639830.1863377307203400.0931688653601698
1140.8837075208867270.2325849582265450.116292479113273
1150.856362593656430.287274812687140.14363740634357
1160.8519843457937220.2960313084125560.148015654206278
1170.8569680719491580.2860638561016830.143031928050842
1180.850915776108260.2981684477834790.149084223891740
1190.8165680625414680.3668638749170640.183431937458532
1200.8634311813469330.2731376373061340.136568818653067
1210.8368959783772140.3262080432455730.163104021622786
1220.8152185525962030.3695628948075940.184781447403797
1230.8021976817511870.3956046364976270.197802318248813
1240.7615172467187920.4769655065624150.238482753281208
1250.7639329777113380.4721340445773240.236067022288662
1260.7547771027604880.4904457944790240.245222897239512
1270.7011668072798280.5976663854403440.298833192720172
1280.664311142846480.6713777143070390.335688857153520
1290.679217672931070.6415646541378610.320782327068931
1300.6809763611633670.6380472776732660.319023638836633
1310.6294336847444620.7411326305110770.370566315255538
1320.6013179625406320.7973640749187370.398682037459368
1330.5885623634079120.8228752731841760.411437636592088
1340.513980516509780.972038966980440.48601948349022
1350.4714562936929490.9429125873858980.528543706307051
1360.4614565555723920.9229131111447850.538543444427608
1370.3862474605728060.7724949211456110.613752539427194
1380.4582887563736830.9165775127473660.541711243626317
1390.8190632535879580.3618734928240830.180936746412042
1400.8259053894498170.3481892211003660.174094610550183
1410.7893785805205810.4212428389588370.210621419479419
1420.7197478789426480.5605042421147050.280252121057352
1430.6574406502340460.6851186995319090.342559349765954
1440.5424511513979680.9150976972040640.457548848602032
1450.6207548605703980.7584902788592030.379245139429602
1460.7729885932620230.4540228134759530.227011406737977
1470.6304131595792420.7391736808415160.369586840420758


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level50.0359712230215827NOK
5% type I error level430.309352517985612NOK
10% type I error level570.410071942446043NOK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/105xor1292381760.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/105xor1292381760.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/1ydrx1292381760.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/1ydrx1292381760.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/2r58i1292381760.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/2r58i1292381760.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/3r58i1292381760.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/3r58i1292381760.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/4r58i1292381760.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/4r58i1292381760.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/52w7l1292381760.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/52w7l1292381760.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/62w7l1292381760.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/62w7l1292381760.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/7c5po1292381760.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/7c5po1292381760.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/8c5po1292381760.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/8c5po1292381760.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/95xor1292381760.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292382697sfztwce3yyuk9nh/95xor1292381760.ps (open in new window)


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