Home » date » 2010 » Dec » 18 »

statistiek Multiple Regression

*The author of this computation has been verified*
R Software Module: /rwasp_multipleregression.wasp (opens new window with default values)
Title produced by software: Multiple Regression
Date of computation: Sat, 18 Dec 2010 19:19:51 +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/18/t1292699881f3krt0n0f5flkto.htm/, Retrieved Sat, 18 Dec 2010 20:18:12 +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/18/t1292699881f3krt0n0f5flkto.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 «
6,5 8,9 -0,6 9 6,3 8,4 1,1 11 5,9 8,1 1,4 13 5,5 8,3 1,4 12 5,2 8,1 1,3 13 4,9 8 1,4 15 5,4 8,7 -0,1 13 5,8 9,2 1,8 16 5,7 9 1,5 10 5,6 8,9 1,5 14 5,5 8,5 1,4 14 5,4 8,1 1,6 15 5,4 7,5 1,6 13 5,4 7,1 1,6 8 5,5 6,9 1,4 7 5,8 7,1 1,7 3 5,7 7 1,8 3 5,4 6,7 1,9 4 5,6 7 2,2 4 5,8 7,3 2,1 0 6,2 7,7 2,4 -4 6,8 8,4 2,6 -14 6,7 8,4 2,8 -18 6,7 8,8 2,7 -8 6,4 9,1 2,6 -1 6,3 9 2,9 1 6,3 8,6 2,8 2 6,4 7,9 2,2 0 6,3 7,7 2,2 1 6 7,8 2,2 0 6,3 9,2 2 -1 6,3 9,4 2 -3 6,6 9,2 1,7 -3 7,5 8,7 1,4 -3 7,8 8,4 1,3 -4 7,9 8,6 1,4 -8 7,8 9 1,3 -9 7,6 9,1 1,3 -13 7,5 8,7 1,4 -18 7,6 8,2 2 -11 7,5 7,9 1,7 -9 7,3 7,9 1,8 -10 7,6 9,1 1,7 -13 7,5 9,4 1,6 -11 7,6 9,4 1,7 -5 7,9 9,1 1,9 -15 7,9 9 1,8 -6 8,1 9,3 1,7 -6 8,2 9,9 1,6 -3 8 9,8 1,8 -1 7,5 9,3 1,6 -3 6,8 8,3 1,5 -4 6,5 8 1,5 -6 6,6 8,5 1,3 0 7,6 10,4 1,4 -4 8 11,1 1,4 -2 8,1 10,9 1,3 -2 7,7 10 1,3 -6 7,5 9,2 1,2 -7 7,6 9,2 1,1 -6 7,8 9,5 1,4 -6 7,8 9,6 1,2 -3 7,8 9,5 1,5 -2 7,5 9,1 1,1 -5 7,5 8,9 1,3 -11 7,1 9 1,5 -1 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 time8 seconds
R Server'Gwilym Jenkins' @ 72.249.127.135


Multiple Linear Regression - Estimated Regression Equation
Mannen[t] = + 3.68452713026474 + 0.426921611066371Vrouwen[t] -0.393998879715656Inflatie[t] -0.0659007049273914Consumvertr[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)3.684527130264740.5636446.53700
Vrouwen0.4269216110663710.0549087.775200
Inflatie-0.3939988797156560.096037-4.10267.6e-053.8e-05
Consumvertr-0.06590070492739140.005595-11.778300


Multiple Linear Regression - Regression Statistics
Multiple R0.827745529807599
R-squared0.685162662116463
Adjusted R-squared0.677020317171199
F-TEST (value)84.148076103678
F-TEST (DF numerator)3
F-TEST (DF denominator)116
p-value0
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation0.49112439590422
Sum Squared Residuals27.9795679812651


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
16.57.12742245223832-0.627422452238318
26.36.112362141333740.187637858666263
35.95.734284584244340.165715415755657
45.55.88556961138501-0.385569611385008
55.25.77368447221591-0.573684472215908
64.95.55979101328292-0.659791013282922
75.46.58143587045765-1.18143587045765
85.85.84859668974891-0.0485966897489136
95.76.27681626101469-0.576816261014685
105.65.97052128019848-0.370521280198483
115.55.8391525237435-0.339152523743499
125.45.52368339844643-0.123683398446428
135.45.399331841661390.000668158338611988
145.45.5580667218718-0.158066721871797
155.55.61738288052905-0.117382880529046
165.85.84817035853719-0.0481703585371886
175.75.76607830945899-0.0660783094589857
185.45.53270123324012-0.132701233240117
195.65.542578052645330.0574219473546677
205.85.97365724364637-0.173657243646375
216.26.28982904386779-0.089829043867792
226.87.16888144494504-0.368881444945035
236.77.35368448871147-0.653684488711469
246.76.90484597183567-0.204845971835669
256.46.6110174086354-0.211017408635406
266.36.31832417375929-0.0183241737592898
276.36.121054712376920.178945287623085
286.46.190410322314630.209589677685368
296.36.039125295173970.260874704826034
3066.147718161208-0.147718161207995
316.36.89010889757144-0.590108897571437
326.37.1072946296395-0.807294629639494
336.67.14010997134092-0.540109971340917
347.57.044848829722430.455151170277573
357.87.022072939301470.777927060698526
367.97.331660193252750.568339806747253
377.87.607729430578250.192270569421747
387.67.91402441139446-0.314024411394456
397.58.0333594036333-0.533359403633299
407.67.122194335778980.47780566422102
417.56.980516106518980.519483893481017
427.37.007016923474810.292983076525191
437.67.7564248595082-0.156424859508194
447.57.79209982094489-0.292099820944888
457.67.357295703408970.242704296591026
467.97.809426493419840.0905735065801552
477.97.213027875938250.686972124061749
488.17.380504247229730.719495752770271
498.27.478354987058940.721645012941057
5087.225061640154390.774938359845609
517.57.222202020419120.277797979580880
526.86.90058100225171-0.100581002251706
536.56.90430592878658-0.404305928786577
546.66.80116228069855-0.201162280698545
557.67.83651627346265-0.236516273462651
5688.00355999135433-0.00355999135432682
578.17.957575557112620.142424442887381
587.77.83694892686245-0.13694892686245
597.57.60071223090831-0.10071223090831
607.67.574211413952480.0257885860475155
617.87.58408823335770.215911766642301
627.87.50787805562530.292121944374707
637.87.281085525676570.518914474323432
647.57.465618547918460.0343814520815443
657.57.6968386793264-0.196838679326399
667.17.6607310644899-0.560731064489905
677.58.28794438854917-0.787944388549175
687.58.18922834192036-0.689228341920362
697.68.44953888849486-0.849538888494856
707.77.71918191634755-0.0191819163475530
717.77.574914088876830.12508591112317
727.97.314603542302340.585396457697663
738.17.33009221152880.769907788471198
748.27.198993476598361.00100652340163
758.27.429510933081960.770489066918038
768.27.120626354055031.07937364594497
777.97.291827651881380.608172348118618
787.36.988824944200250.311175055799749
796.97.25156245711022-0.351562457110217
806.67.37634666729506-0.776346667295057
816.77.25156245711022-0.551562457110217
826.96.892698495782160.00730150421783795
8376.86992260536120.130077394638792
847.17.42362906173616-0.323629061736165
857.27.005016288351060.194983711648938
867.16.833814990524710.266185009475286
876.96.84741673646480.0525832635352007
8876.692406782789260.307593217210738
896.86.561038026334280.238961973665720
906.46.49227770167162-0.0922777016716169
916.76.627371384661470.0726286153385288
926.66.525795718297390.074204281702614
936.46.43382684981397-0.0338268498139682
946.36.33511080318515-0.0351108031851547
956.26.75701584970533-0.557015849705329
966.56.41790552718770.0820944728122966
976.86.467614887964280.332385112035716
986.86.14183628986220.658163710137802
996.45.888975596357450.511024403642554
1006.16.18210148463336-0.0821014846333637
1015.86.06762674725354-0.267626747253538
1026.16.25199713762017-0.151997137620173
1037.26.938796641861240.261203358138762
1047.36.981056149568070.318943850431925
1056.96.639086207315180.260913792684822
1066.16.9561233143362-0.856123314336196
1075.87.19365797048974-1.39365797048974
1086.27.59823634453495-1.39823634453495
1097.17.67919306528901-0.579193065289009
1107.77.86728838219052-0.167288382190515
11187.860703835920370.139296164079629
1127.87.354549795511070.445450204488931
1137.47.104278700217040.295721299782957
1147.47.205854366581130.194145633418871
1157.77.80985914681964-0.109859146819645
1167.87.542531400575210.257468599424792
1177.87.292962980205530.507037019794471
11887.217618109272720.782381890727277
1198.17.082524426282871.01747557371713
1208.47.622196483317940.777803516682061


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
70.3718980824659080.7437961649318160.628101917534092
80.2517307940109190.5034615880218380.74826920598908
90.545745991831760.9085080163364790.454254008168239
100.4241401274070540.8482802548141080.575859872592946
110.3179813800020620.6359627600041240.682018619997938
120.2409673008269590.4819346016539180.759032699173041
130.1706951569383260.3413903138766520.829304843061674
140.1315056079819560.2630112159639130.868494392018044
150.08968244882357240.1793648976471450.910317551176428
160.05968977236975870.1193795447395170.94031022763024
170.03910638507814630.07821277015629260.960893614921854
180.02767513602322450.0553502720464490.972324863976776
190.01662865292261340.03325730584522670.983371347077387
200.01186250349611290.02372500699222570.988137496503887
210.00691564875382010.01383129750764020.99308435124618
220.004285225969939730.008570451939879470.99571477403006
230.003492385484986830.006984770969973650.996507614515013
240.002078610379629610.004157220759259220.99792138962037
250.001129395543021890.002258791086043770.998870604456978
260.0006242651691034940.001248530338206990.999375734830896
270.0004428423769139010.0008856847538278030.999557157623086
280.0004839716128967190.0009679432257934380.999516028387103
290.0004925971789902250.000985194357980450.99950740282101
300.0002799174724574820.0005598349449149650.999720082527543
310.0002169140756212450.000433828151242490.999783085924379
320.0002634439012128570.0005268878024257130.999736556098787
330.0001804199423093690.0003608398846187380.99981958005769
340.004916466480246320.009832932960492640.995083533519754
350.06086418582131450.1217283716426290.939135814178686
360.1171231538723680.2342463077447360.882876846127632
370.1098441581144020.2196883162288040.890155841885598
380.08777415765114750.1755483153022950.912225842348853
390.08412446093373340.1682489218674670.915875539066267
400.0955568835518240.1911137671036480.904443116448176
410.1038581836984990.2077163673969980.8961418163015
420.08696458525976720.1739291705195340.913035414740233
430.06628317829038520.1325663565807700.933716821709615
440.05109671010691320.1021934202138260.948903289893087
450.05119927675402340.1023985535080470.948800723245977
460.0402644017702510.0805288035405020.959735598229749
470.07275266489524770.1455053297904950.927247335104752
480.1267460273881260.2534920547762520.873253972611874
490.2044748805573290.4089497611146580.795525119442671
500.2969034593490630.5938069186981270.703096540650937
510.2662101149155750.532420229831150.733789885084425
520.2338197837679870.4676395675359740.766180216232013
530.2474966104749950.494993220949990.752503389525005
540.2397484733597310.4794969467194610.76025152664027
550.2058154436151180.4116308872302350.794184556384882
560.1715226636438380.3430453272876770.828477336356162
570.1468456412886260.2936912825772530.853154358711374
580.1195247227582760.2390494455165520.880475277241724
590.09833023817950490.1966604763590100.901669761820495
600.07925578436244060.1585115687248810.92074421563756
610.0645282102321030.1290564204642060.935471789767897
620.0543942985113130.1087885970226260.945605701488687
630.05643361077739840.1128672215547970.943566389222602
640.04447886506330940.08895773012661880.95552113493669
650.03706055266448520.07412110532897040.962939447335515
660.04619639288585660.09239278577171320.953803607114143
670.0783836611248570.1567673222497140.921616338875143
680.1000633844748040.2001267689496090.899936615525196
690.1708983774585030.3417967549170070.829101622541497
700.1432406102585240.2864812205170480.856759389741476
710.1174354981246120.2348709962492240.882564501875388
720.1251046160221630.2502092320443250.874895383977837
730.1511660419794410.3023320839588810.84883395802056
740.2531850985051820.5063701970103640.746814901494818
750.2873709179412850.5747418358825710.712629082058715
760.4591106481242790.9182212962485590.54088935187572
770.4702594504216390.9405189008432780.529740549578361
780.4278601097198060.8557202194396120.572139890280194
790.3941788371040380.7883576742080760.605821162895962
800.4746701272918050.949340254583610.525329872708195
810.5040554422477180.9918891155045640.495944557752282
820.4635951138001520.9271902276003030.536404886199848
830.4204116753658740.8408233507317490.579588324634126
840.4336476193998420.8672952387996840.566352380600158
850.3878603993378570.7757207986757140.612139600662143
860.3419902354384950.683980470876990.658009764561505
870.2982899519106880.5965799038213770.701710048089312
880.2540975813640170.5081951627280340.745902418635983
890.2157297303961480.4314594607922970.784270269603851
900.2266698132136790.4533396264273580.773330186786321
910.2144055369689690.4288110739379370.785594463031031
920.1986987397458070.3973974794916150.801301260254192
930.2259163753615540.4518327507231090.774083624638446
940.2655760714766160.5311521429532310.734423928523384
950.4607196154070990.9214392308141990.5392803845929
960.4492432343800780.8984864687601560.550756765619922
970.3855283123069760.7710566246139520.614471687693024
980.341969348645050.68393869729010.65803065135495
990.2914699107784030.5829398215568070.708530089221597
1000.2838208130011280.5676416260022560.716179186998872
1010.3059595464926020.6119190929852040.694040453507398
1020.2815095116527420.5630190233054840.718490488347258
1030.2378964661045200.4757929322090410.76210353389548
1040.2341078325695960.4682156651391910.765892167430404
1050.2734028047411320.5468056094822630.726597195258868
1060.241742476112240.483484952224480.75825752388776
1070.4559520033930710.9119040067861430.544047996606929
1080.8917980413934710.2164039172130570.108201958606529
1090.971454061243680.057091877512640.02854593875632
1100.938932470556080.1221350588878400.0610675294439202
1110.904390589942090.1912188201158180.095609410057909
1120.9870428807097960.02591423858040830.0129571192902042
1130.9568136105016230.08637277899675390.0431863894983769


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level130.121495327102804NOK
5% type I error level170.158878504672897NOK
10% type I error level250.233644859813084NOK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/10tyit1292699982.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/10tyit1292699982.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/1mf3z1292699982.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/1mf3z1292699982.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/2x6221292699982.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/2x6221292699982.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/3x6221292699982.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/3x6221292699982.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/4x6221292699982.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/4x6221292699982.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/5x6221292699982.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/5x6221292699982.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/6qgk51292699982.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/6qgk51292699982.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/7ip1q1292699982.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/7ip1q1292699982.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/8ip1q1292699982.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/8ip1q1292699982.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/9ip1q1292699982.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/18/t1292699881f3krt0n0f5flkto/9ip1q1292699982.ps (open in new window)


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