Home » date » 2010 » Nov » 26 »

W8 Regressiemodel

*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: Fri, 26 Nov 2010 11:00:47 +0000
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n.htm/, Retrieved Fri, 26 Nov 2010 11:59:23 +0100
 
BibTeX entries for LaTeX users:
@Manual{KEY,
    author = {{YOUR NAME}},
    publisher = {Office for Research Development and Education},
    title = {Statistical Computations at FreeStatistics.org, URL http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n.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 «
14.458 13.594 17.814 20.235 21.811 21.439 21.393 19.831 20.468 21.080 21.600 17.390 17848 19592 21092 20889 25890 24965 22225 20977 22897 22785 22769 19637 20203 20450 23083 21738 26766 25280 22574 22729 21378 22902 24989 21116 15169 15846 20927 18273 22538 15596 14034 11366 14861 15149 13577 13026 13190 13196 15826 14733 16307 15703 14589 12043 15057 14053 12698 10888 10045 11549 13767 12424 13116 14211 12266 12602 15714 13742 12745 10491 10057 10900 11771 11992 11993 14504 11727 11477 13578 11555 11846 11397 10066 10269 14279 13870 13695 14420 11424 9704 12464 14301 13464 9893 11572 12380 16692 16052 16459 14761 13654 13480 18068 16560 14530 10650 11651 13735 13360 17818 20613 16231 13862 12004 17734 15034 12609 12320 10833 11350 13648 14890 16325 18045 15616 11926 16855 15083 12520 12355
 
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 time7 seconds
R Server'Sir Ronald Aylmer Fisher' @ 193.190.124.24


Multiple Linear Regression - Estimated Regression Equation
Pas[t] = + 11516.7062045455 -32.8866979166674M1[t] + 745.405183712119M2[t] + 3028.25015625000M3[t] + 2861.47703787879M4[t] + 4766.35437405303M5[t] + 3852.05461931818M6[t] + 1868.78450094697M7[t] + 620.103837121209M8[t] + 3368.07762784091M9[t] + 2685.14005492424M10[t] + 1822.64866382575M11[t] + 6.44775473484847t + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)11516.70620454552087.7650235.516300
M1-32.88669791666742594.083062-0.01270.9899060.494953
M2745.4051837121192593.297560.28740.7742790.387139
M33028.250156250002592.5866621.1680.2451250.122562
M42861.477037878792591.9504311.1040.2718270.135913
M54766.354374053032591.3889211.83930.0683630.034182
M63852.054619318182590.902181.48680.1397220.069861
M71868.784500946972590.4902510.72140.4720770.236039
M8620.1038371212092590.1531690.23940.8112010.4056
M93368.077627840912589.8909641.30050.1959530.097976
M102685.140054924242589.7036591.03690.3019070.150954
M111822.648663825752589.5912690.70380.482910.241455
t6.4477547348484713.9295820.46290.6442940.322147


Multiple Linear Regression - Regression Statistics
Multiple R0.253366532834073
R-squared0.0641945999603596
Adjusted R-squared-0.0301723311360749
F-TEST (value)0.680265843283159
F-TEST (DF numerator)12
F-TEST (DF denominator)119
p-value0.767537094382899
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation6073.04198876287
Sum Squared Residuals4388938840.67594


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
114.45811490.2672613636-11475.8092613636
213.59412275.0068977273-12261.4128977273
317.81414564.299625-14546.485625
420.23514403.9742613636-14383.7392613636
521.81116315.2993522727-16293.4883522727
621.43915407.4473522727-15386.0083522727
721.39313430.6249886364-13409.2319886364
819.83112188.3920795455-12168.5610795455
920.46814942.813625-14922.345625
1021.0814266.3238068182-14245.2438068182
1121.613410.2801704545-13388.6801704545
1217.3911594.0792613636-11576.6892613636
131784811567.64031818186280.35968181818
141959212352.37995454557239.62004545455
152109214641.67268181826450.32731818182
162088914481.34731818186407.65268181818
172589016392.67240909099497.32759090909
182496515484.82040909099480.1795909091
192222513507.99804545458717.00195454545
202097712265.76513636368711.23486363637
212289715020.18668181827876.81331818181
222278514343.69686363648441.30313636363
232276913487.65322727279281.34677272727
241963711671.45231818187965.54768181818
252020311645.0133758557.986625
262045012429.75301136368020.24698863637
272308314719.04573863648363.95426136363
282173814558.7203757179.279625
292676616470.045465909110295.9545340909
302528015562.19346590919717.8065340909
312257413585.37110227278988.62889772727
322272912343.138193181810385.8618068182
332137815097.55973863646280.44026136364
342290214421.06992045458480.93007954545
352498913565.026284090911423.9737159091
362111611748.8253759367.174625
371516911722.38643181823446.61356818182
381584612507.12606818183338.87393181818
392092714796.41879545456130.58120454545
401827314636.09343181823636.90656818182
412253816547.41852272735990.58147727273
421559615639.5665227273-43.5665227272722
431403413662.7441590909371.255840909091
441136612420.51125-1054.51125000000
451486115174.9327954545-313.932795454544
461514914498.4429772727650.557022727276
471357713642.3993409091-65.3993409090896
481302611826.19843181821199.80156818181
491319011799.75948863641390.24051136363
501319612584.499125611.500875
511582614873.7918522727952.208147727272
521473314713.466488636419.5335113636345
531630716624.7915795455-317.791579545453
541570315716.9395795455-13.9395795454540
551458913740.1172159091848.88278409091
561204312497.8843068182-454.884306818183
571505715252.3058522727-195.305852272726
581405314575.8160340909-522.816034090907
591269813719.7723977273-1021.77239772727
601088811903.5714886364-1015.57148863637
611004511877.1325454545-1832.13254545455
621154912661.8721818182-1112.87218181818
631376714951.1649090909-1184.16490909091
641242414790.8395454545-2366.83954545455
651311616702.1646363636-3586.16463636363
661421115794.3126363636-1583.31263636364
671226613817.4902727273-1551.49027272727
681260212575.257363636426.7426363636362
691571415329.6789090909384.321090909093
701374214653.1890909091-911.18909090909
711274513797.1454545455-1052.14545454545
721049111980.9445454545-1489.94454545455
731005711954.5056022727-1897.50560227273
741090012739.2452386364-1839.24523863636
751177115028.5379659091-3257.53796590909
761199214868.2126022727-2876.21260227273
771199316779.5376931818-4786.53769318182
781450415871.6856931818-1367.68569318182
791172713894.8633295455-2167.86332954546
801147712652.6304204545-1175.63042045455
811357815407.0519659091-1829.05196590909
821155514730.5621477273-3175.56214772727
831184613874.5185113636-2028.51851136364
841139712058.3176022727-661.31760227273
851006612031.8786590909-1965.87865909091
861026912816.6182954545-2547.61829545454
871427915105.9110227273-826.911022727272
881387014945.5856590909-1075.58565909091
891369516856.91075-3161.91075
901442015949.05875-1529.05875
911142413972.2363863636-2548.23638636364
92970412730.0034772727-3026.00347727273
931246415484.4250227273-3020.42502272727
941430114807.9352045455-506.935204545452
951346413951.8915681818-487.891568181817
96989312135.6906590909-2242.69065909091
971157212109.2517159091-537.251715909092
981238012893.9913522727-513.991352272726
991669215183.28407954551508.71592045455
1001605215022.95871590911029.04128409091
1011645916934.2838068182-475.28380681818
1021476116026.4318068182-1265.43180681818
1031365414049.6094431818-395.609443181818
1041348012807.3765340909672.623465909092
1051806815561.79807954552506.20192045455
1061656014885.30826136361674.69173863637
1071453014029.264625500.735375000003
1081065012213.0637159091-1563.06371590909
1091165112186.6247727273-535.624772727274
1101373512971.3644090909763.635590909092
1111336015260.6571363636-1900.65713636364
1121781815100.33177272732717.66822727273
1132061317011.65686363643601.34313636364
1141623116103.8048636364127.195136363638
1151386214126.9825-264.982499999999
1161200412884.7495909091-880.749590909091
1171773415639.17113636362094.82886363637
1181503414962.681318181871.3186818181851
1191260914106.6376818182-1497.63768181818
1201232012290.436772727329.5632272727255
1211083312263.9978295455-1430.99782954546
1221135013048.7374659091-1698.73746590909
1231364815338.0301931818-1690.03019318182
1241489015177.7048295455-287.704829545454
1251632517089.0299204545-764.029920454543
1261804516181.17792045451863.82207954546
1271561614204.35555681821411.64444318182
1281192612962.1226477273-1036.12264772727
1291685515716.54419318181138.45580681818
1301508315040.05437542.9456250000042
1311252014184.0107386364-1664.01073863636
1321235512367.8098295455-12.8098295454563


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
160.04466947021710010.08933894043420020.9553305297829
170.2177951391744730.4355902783489460.782204860825527
180.2069484246159600.4138968492319200.79305157538404
190.1230021555675940.2460043111351890.876997844432406
200.07134265500176860.1426853100035370.928657344998231
210.04084069138094660.08168138276189320.959159308619053
220.02251916835800430.04503833671600850.977480831641996
230.01245626446012620.02491252892025240.987543735539874
240.009208815005781420.01841763001156280.990791184994219
250.9895713752099780.02085724958004390.0104286247900220
260.999887003833390.0002259923332195930.000112996166609796
270.9999883546747862.32906504274421e-051.16453252137211e-05
280.9999981325740663.73485186844505e-061.86742593422252e-06
290.9999995744683318.51063337608523e-074.25531668804261e-07
300.9999999141488361.71702327833412e-078.58511639167061e-08
310.9999999853001682.93996636958791e-081.46998318479396e-08
320.9999999989269722.14605675328575e-091.07302837664287e-09
330.999999999645417.09180906061965e-103.54590453030983e-10
340.9999999999453671.09265111156789e-105.46325555783946e-11
350.9999999999997624.7653891972433e-132.38269459862165e-13
3611.91329174150928e-159.56645870754638e-16
3717.8066204954338e-193.9033102477169e-19
3813.69556328537189e-211.84778164268595e-21
3919.86093781566029e-244.93046890783014e-24
4014.36821141735872e-252.18410570867936e-25
4111.05992621743059e-285.29963108715296e-29
4211.30134624421135e-296.50673122105673e-30
4313.13412898732319e-301.56706449366159e-30
4418.66840979567252e-314.33420489783626e-31
4511.06822080726673e-305.34110403633363e-31
4611.05786641852041e-305.28933209260205e-31
4718.13912135642193e-314.06956067821096e-31
4814.52487437541523e-312.26243718770762e-31
4911.01984837220099e-315.09924186100497e-32
5016.0865066063739e-323.04325330318695e-32
5112.80563036045276e-321.40281518022638e-32
5215.37436586866497e-322.68718293433248e-32
5315.04670452763168e-322.52335226381584e-32
5411.02214817307039e-315.11074086535195e-32
5518.05388788693352e-324.02694394346676e-32
5611.63607705432227e-318.18038527161135e-32
5716.50564532722289e-313.25282266361145e-31
5811.96841100336608e-309.84205501683039e-31
5914.96832028371087e-302.48416014185543e-30
6011.31415574018369e-296.57077870091843e-30
6113.99781116601239e-291.99890558300620e-29
6211.12334424053747e-285.61672120268735e-29
6313.18940627190774e-281.59470313595387e-28
6411.18240212709421e-275.91201063547105e-28
6513.31436246355277e-271.65718123177638e-27
6611.56223291974110e-267.81116459870548e-27
6716.87657093711081e-263.43828546855541e-26
6811.13190559507520e-255.65952797537598e-26
6913.63200832673205e-251.81600416336602e-25
7011.51292993941597e-247.56464969707984e-25
7114.54038756860062e-242.27019378430031e-24
7211.73569558207494e-238.67847791037469e-24
7317.46037915896143e-233.73018957948071e-23
7413.27516659137081e-221.63758329568541e-22
7511.25688207486982e-216.2844103743491e-22
7613.24029247958044e-211.62014623979022e-21
7712.47537819770185e-211.23768909885092e-21
7811.29641431436841e-206.48207157184203e-21
7916.29727439672095e-203.14863719836048e-20
8012.54259644977851e-191.27129822488926e-19
8111.02208179426063e-185.11040897130313e-19
8212.08215305619356e-181.04107652809678e-18
8311.02484472507311e-175.12422362536555e-18
8413.73944531377065e-171.86972265688533e-17
8511.80495537517788e-169.02477687588941e-17
8617.0941935887671e-163.54709679438355e-16
870.9999999999999983.15141190595537e-151.57570595297769e-15
880.9999999999999941.18330028544004e-145.91650142720019e-15
890.9999999999999931.32085544240374e-146.6042772120187e-15
900.9999999999999745.24192599970922e-142.62096299985461e-14
910.9999999999999431.14847958459624e-135.74239792298119e-14
920.9999999999998762.47122402176736e-131.23561201088368e-13
930.999999999999991.90360410643387e-149.51802053216936e-15
940.9999999999999647.25831813073968e-143.62915906536984e-14
950.99999999999984.00130313613739e-132.00065156806869e-13
960.9999999999995838.3478179288123e-134.17390896440615e-13
970.9999999999977184.56301685163247e-122.28150842581624e-12
980.9999999999883832.32341676778831e-111.16170838389415e-11
990.999999999985652.87006607660736e-111.43503303830368e-11
1000.9999999999255041.48991945792713e-107.44959728963564e-11
1010.9999999998430743.13852264540182e-101.56926132270091e-10
1020.9999999998317313.36537443494355e-101.68268721747177e-10
1030.9999999995272879.45425183683165e-104.72712591841582e-10
1040.9999999975056184.98876375657457e-092.49438187828728e-09
1050.9999999861332962.77334073040907e-081.38667036520454e-08
1060.9999999325175541.34964892834633e-076.74824464173167e-08
1070.9999997487059985.02588004602093e-072.51294002301047e-07
1080.9999995170513739.6589725301962e-074.8294862650981e-07
1090.9999973877189655.22456206978607e-062.61228103489303e-06
1100.9999913012962991.73974074028618e-058.69870370143092e-06
1110.9999583014965678.33970068654296e-054.16985034327148e-05
1120.9999068032143950.0001863935712091829.3196785604591e-05
1130.9999923121874831.53756250334749e-057.68781251673744e-06
1140.999978452794144.30944117199411e-052.15472058599705e-05
1150.9999936221385681.27557228635836e-056.37786143179179e-06
1160.9998448933393780.0003102133212442870.000155106660622144


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level910.900990099009901NOK
5% type I error level950.94059405940594NOK
10% type I error level970.96039603960396NOK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/104dj31290769236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/104dj31290769236.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/1fc491290769236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/1fc491290769236.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/2fc491290769236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/2fc491290769236.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/3q3lu1290769236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/3q3lu1290769236.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/4q3lu1290769236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/4q3lu1290769236.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/5q3lu1290769236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/5q3lu1290769236.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/61c3x1290769236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/61c3x1290769236.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/7b3k01290769236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/7b3k01290769236.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/8b3k01290769236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/8b3k01290769236.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/9b3k01290769236.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/26/t1290769162i0q02xiz9ggbc3n/9b3k01290769236.ps (open in new window)


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