一元线性回归模型案例_第1页
一元线性回归模型案例_第2页
一元线性回归模型案例_第3页
一元线性回归模型案例_第4页
一元线性回归模型案例_第5页
已阅读5页,还剩21页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

1、第二章一元线性回归模型案例一、中国居民人均消费模型从总体上考察中国居民收入与消费支出的关系。表2.1给出了佃90年不变价格测算的中国人均国内生产总值(GDPP )与以居民消费价格指数( 佃90年为100)所见的人均居民 消费支出(CONSP )两组数据。表2.1中国居民人均消费支出与人均 GDP (单位:元/人)年份CONSPGDPP年份CONSPGDPP1978395.8000675.10001990797.10001602.3001979437.0000716.90001991861.40001727.2001980464.1000763.70001992966.60001949.8001

2、981501.9000792.400019931048.6002187.9001982533.5000851.100019941108.7002436.1001983572.8000931.400019951213.1002663.7001984635.60001059.20019961322.8002889.1001985716.00001185.20019971380.9003111.9001986746.50001269.60019981460.6003323.1001987788.30001393.60019991564.4003529.3001988836.40001527.0002

3、0001690.8003789.7001989779.70001565.9001)建立模型,并分析结果。输出结果为:D即endent Variable: CONSP Method: Least Squares Dale. 07/O2/D8 Time: 20.13Sample: 1978 2000Included observations: 23VariableCoefficientStd Error t-StatisticProb.C201 118914 3840213.512410.0000GDPP0.3861800 00722253 474710 0000R-squared0.992710

4、Mean dependent var905.3304Adjusted R-squared0 992363S.D dependent var3S06334S.E. cf regression33.26450Akaike info criterion9 929300Sum squared resid23237.06Schwarz criterion10.02854Log likelihood-1121927Fatalistic2859.544Durbin-Watson statQ550636Prob(F'Statistiic)0 000000对应的模型表达式为:CONSP =201.107

5、0.3862GDPP2(13.51)(53.47) R =0.9927,F =2859.23,DW =0.55从回归估计的结果可以看出,拟合度较好,截距项和斜率项系数均通过了t检验。中国人均消费增加 10000元,GDP增加3862元。二、线性回归模型估计表2.2给出黑龙江省伊春林区 1999年16个林业局的年木材采伐量和相应伐木剩余物数据。利用该数据(1)画散点图;(2)进行OLS回归;(3)预测。表2.2年剩余物yt和年木材采伐量xt数据林业局名年木材剩余物yt (万m )年木材采伐量 xt (万m )乌伊岭26.1361.4东风23.4948.3新冃21.9751.8红星11.5335.

6、9五营7.1817.8上甘岭6.8017.0友好18.4355.0翠峦11.6932.7乌马河6.8017.0美溪9.6927.3大丰7.9921.5南岔12.1535.5带岭6.8017.0朗乡17.2050.0桃山9.5030.0双丰5.5213.8合计202.87532.00(1)画散点图©ETiewsFile Edi t Obj act ¥i ew Free Quick Dptionz Wiikdotf K*LpO >orkfile:CASEl -(d讪申 Pr oc ObiectPrint SaveDehcRange: 1 16-16 obsSample:

7、1 1616 obscoCJ 艺 X AbSI3ESGraphEmpty Group (Edit Seri es)Seri_电百 Statistics Gtqur Statisties Estimate Equation. a sVAR.nraj?aiLine graphBar graphScatterJJ lineFi先输入横轴变量名,再输入纵轴变量名得散点图(2) OLS估计肅 EViewsFile Edit Obj ect ¥i ew Proc Quick OEtioris Window Helpsiurex y弹出方程设定对话框Equation Estiaation得到输出结

8、果如图:® EVieTs - Equation: UHTITLED lorkfile: CASEHCaselL_l Fil« Edit OLj#ct Vi ew Prcc Quick ORtionw 世 iivdovr HlpView Proc | Object Print Name FreezeEstimate Forecast 15tats Reside |Dependent Variable: YMethod: Least SquaresDate: O6Z28AJ8 Time: 18:20Sample: 1 16Included observations: 16Var

9、iableCoefficientStd. Error (-StatisticProbC-0.7629281 220966-0.6248560.5421X0.4042800.03337712.112G60.0000R-squared0.912S90Mean dependent var12.67937Adjusted R-squared1906668S D dependent var6GS546GS.E. of regnession2 036319Akaike info criterion4.376G33Sum squared resid58.05231Schwarz criterion4 473

10、207Log likelihood33.01306F-statistic14671B6Durbin-Watsan stat1 401946Prob(F-statistic)0.000000由输出结果可以看出,对应的回归表达式为:乂二-0.7629 0.4043X(-0.625)(12.11)R2 =0.9129,F =146.7166,DW =1.48(3) x=20条件下模型的样本外预测方法 首先修改工作文件范围File Edi t Obj ect View Proe Qmiuk OjtiorLS Wiitd&w Help loTkfile: CASE1 - (d:深杵*航畝c鮎el

11、 vf 1)也竺J至也盍。曲亡代Print話的日恥岀117+卜shoTFRJsgru Del&te &nrSampleR 朗 St Sample.Display Filter: *cr>Structure/Rtsi ze Current Fige. Append to Current Page. Contract Current f age.R« shape Curr ent FCopy/Extract from Current Pa莒亡 Sirt Current Page.将工作文件范围从 1 16改为1 17Vorkfile structureXIWorkf

12、ile structure typDated " regular frequencyFrequencyStiartEndCim.cel确定后将工作文件的范围改为包括17个观测值,然后修改样本范围File Edi t Object View Proc gui ck Options Window Help口 Torkfile: CASE1 - (d:® 件砲昶 rf 1) 口回岡|v<ewSet S毓pl筑Stiruet口r电/Resize Current Page. Append t® Cwt电:nt Page, r B Contract Current Pa

13、ge. . Reshaps Current PageC&py/Extract from Current Page Sort Current Page.5toreDelete,|Genr,|3amplEDisplay Filter:将样本范围从 116改为1 17 二SaapleSample rafige pairs (or samp 1 e object to copy)1 17IF condition (optional)Cancel打开x的数据文件,利用Edit+/-给x的第17个观测值赋值为 20圍CS resid叼x0 Y17|OKo由上图可以知道,当x=20时,y的预测值是7

14、.32, yf的分布标准差是 2.145。 Group: UNTITLED Torkfile: CASE1:Casel将Forecast sample选择区把预测范围从 1 17改为1717,即只预测 x=20时的y的值。Dependent Variable: Y Method: Least Squares Date: 06/29/08 Time: 18:17 Sample (adjusted): 1 16 Included observations: 16 after adjuVariableCoefficientForecastFile gdi t Otject View Froc Qui

15、ck Otions irtdow Help 卑ieydArcx Jobjei± PrintHfJmme|Freeae Estinnate Fore£ast.S 兰 ts Re si ch-0.7629280.404280R-squared Adjusted R-squared S. E. of regression Sum squared resid Log likelihood Durbin-Watson stat0.9128900.906E6B2.03631958.05231-33.013061.43194EDB = noneWF = easelPath.二 c: do

16、 elements :and s e 11 i ngs zhuy i x i my documentSeries namesMethodStatic forecast(mo dynami ue in1 fhTh、.ctural (i gnor e X uncertainty in :S. EEInsert act7i:ils for oxit一o壬-sample obsCancelEquati onUBTITLEDForecastGAECH Cop t i onalForecast sampleOutputForecast graph Forecast evaluat Series: X

17、65;orkflie: CASEl:Casel三Object Properties Print Name |Defaukv Sort |Edt+/-|5iifipl+/Jlat20 K11027.30000lA1121.500001235 500001317.000001450.000001530.000001G13.80000| 1720|<1|>)EViers Equation: UKTITLED Torkflie: CASE1 = :Caselpi空世匹objet£ printNameJjFreeze Defaultv Sort TransposeEdit+/- 5

18、mpl+y- InsobsYFyfse|17 JNA7.3226682140072叵<A|Dill>三、表2.3列出了中国1978 2000年的参政收入 Y和国内生产总值 GDP的统计资料。做 出散点图,建立财政收入随国内生产总值变化的一元线性回归方程。表2.3中国历年财政收入与 GDP数据年份财政收入YGDP年份财政收入YGDP19781132.2603624.10019902937.10018547.9019791146.3804038.20019913149.48021617.8019801159.9304517.80019923483.37026638.1019811175

19、.7904862.40019934348.95034634.4019821212.3305294.70019945218.10046759.4019831366.9505934.50019956242.20058478.1019841642.8607171.00019967407.99067884.6019852004.8208964.40019978651.14074462.6019862122.01010202.2019989875.95078345.2019872199.35011962.50199911444.0882067.5019882357.24014928.3020001339

20、5.2389403.6019892664.90016909.201)做散点图:E¥iewsI 二_口 因Series ListList cf series, groupand/or series expressions 国曲y得到散点图如下:14000 12000100008000-A6000400020000 000GDP2)进行回归分析:输出结果如下:Dependent Variable: YMethod: Least SquaresDate: 07/02)8 Time: 20:48Sample: 1978 2000Included observations: 23Variabl

21、eCoefficientStd. Error卜StatisticProb.C556.6477220.89432.5199730.0199GDP0J196070 0052732Z7229B0.0000R-squared0.96091 aMean dependsrit var4188.627Adjusted R-squared0 959057S.D. dependent var3613700S.IE. of regression731.2086Akaike info criterion16.11022Sum squared resid11227988Schwarz criterion16.2089

22、6Log likelih口od-ia3.2675F-statistic516.3338Durbin-Watson stat0 347372Prob(F-statistic)0.000000对应的表达式是:Y =556.6 0.12GDP2(2.52)(22.72)R =0.96,F =516.3从上面的结果可以看出,模型的你拟合度较高,各个系数均通过了t检验。财政收入增加 10000元,GDP增加1200元。四、表2.4给出了某国 佃90佃96年间的CPI指数与S&P500指数。(1)以CPI指数为横 轴,S&P500指数为纵轴作图;(2)做回归模型,并解释结果。表2.4 某国

23、历年CPI与标准普尔指数年份CPI指数S&P500指数年份CPI指数S&P500指数1990130.7000334.59001994148.2000460.33001991136.20003764000541.64001992140.3000415.74001996159.6000670.83001993144.5000451.41001)作散点图:EVievs:-|口医Fils口叵e : SduiTi Aixt c utd IE aSeriesi st i csGr qplr :S t at 1 s 11, c s Estirrite EQuatio

24、n.E ie-L i. m-ch.'t« V AH .Qimiulc Ot i otle W i Tidow HalpCO WnrtTilet ITViewpoc°bj9c±(PGraphRange: 1990 199iSample: 1990 199i ®c0 CpiS resid0 serOl<hJ呂w Hag台/O IM T得散点图如下:Ert山 S68006005605204804404003603205o r3 ,JI5 r340hmple CPI2)做回归估计:得到如下结果:Dependent Variable: SERD1Me

25、thod: Least SquaresDate: 07AJ3/08 Time: 11:11Sample: 1990 1996Included observations: 7Va riableCoefficientStd Error1-StatisticProb.C*1137.826177.9488-6.394122O.DOUCPI11.083611 2285559 0216620.0003R-squared0.942123Mean dependent var464 38B6Adjusted F?-squared0.930548S D. dependent var112.3728S.E. of

26、regression29,61448Akaike info criterion9.849360Sum squared resid4305006Schwarz criterion9.833906Log likelihood-32 47276F-etatistic81 39039Durbin-Watson stat1.187041Prob(F-statistic)0.000279对应的回归表达式为:S& P 二-1137.83 11.08CPI(-6.39)(9.02)回归结果显示,CPI指数与S&P指数正相关,斜率表示当 CPI指数变化1个点,会使 S&P指数变化11.0

27、8个点;截距表示当CPI指数为0是,S&P指数为-1137.83,此数据没有 明显的经济意义。五、表2.5给出了美国30所知名学校的 MBA学生1994年基本年薪(ASP),GPA分数(从 1 4共四个等级),GMAT分数,以及每年学费(X)的数据。(1)用双变量回归模型分析 GPA分数是否对 ASP有影响?(2)用合适的回归模型分析 GMAT分数是否与 ASP有关?(3)每年的学费与ASP有关吗?如果两变量之间正相关,是否意味着进到最高费用的商业学校是有利的?(4)高学费的商业学校意味着高质量的MBA成绩吗?为什么表2.5美国30所知名学校的MBA学生情况学校ASP/美兀GPA分数G

28、MAT分数X/美兀Harvard102630.03.400000650.000023894.00Sta nford100800.03.300000665.000021189.00Columbia n100480.03.300000640.000021400.00Dartmouth95410.003.400000660.000021225.00Wharto n89930.003.400000650.000021050.00Northwestern84640.003.300000640.000020634.00Chicago83210.003.300000650.000021656.00MIT80

29、500.003.500000650.000021690.00Virgi nia74280.003.200000643.000017839.00UCLA74010.003.500000640.000014496.00Berkeley71970.003.200000647.000014361.00Cornell71970.003.200000630.000020400.00NUY70660.003.200000630.000020276.00Duke70490.003.300000623.000021910.00Carn egieMello n59890.003.200000635.0000206

30、00.00North Caroli na69880.003.200000621.000010132.00Michiga n67820.003.200000630.000020960.00Texas61890.003.300000625.00008580.000In dia na58520.003.200000615.000014036.00Purdue54720.003.200000581.00009556.000Case Wester n57200.003.100000591.000017600.00Georgetow n69830.003.200000619.000019584.00Mic

31、higan State41820.003.200000590.000016057.00Penn State49120.003.200000580.000011400.00Souther nMethodist60910.003.100000600.000018034.00Tula ne44080.003.100000600.000019550.00Illi nois47130.003.200000616.000012628.00Lowa41620.003.200000590.00009361.000Minn esota48250.003.200000600.000012618.00Wash in

32、gton44140.003.300000617.000011436.00上述数据是个截面数据,建立数据文件过程如下:Workfilft structTire type:Unstructured / Wdate VObservationIrr egiar 息辻 andNjnes options!WF:Page:OKCarLC«lPan*l workfiles. may be made from Unstructured workflifts by later specifying date and/or然后输入数据即可。(1) 以ASP为因变量,GPA为自变量进行回归分析。结果如下:D

33、ependent Variable: SERO1Method: Least SquaresDate 07X)3/00 Time: 13:D2Sample: 1 30Included observations: 30VariableCoefficientStd Errort-StatisticProbC-273722.595759 31-3.1917900.0035SER02105117 626347.093 9897230 0004R-squared0.362447Mean dependeni var6S2B0.00Adjusted squared0.339677S D dependent v

34、ar18187.78S E. of regression14779 44Akaike info criterion22.10420Sum squared resid6.12E-HJ9Schwarz criteinon22 19762Log likelihood-329.5630F-statistic15.91789Durbin-Watson stat1 006276Prjb(F-stsrtislic)0 000432从回归结果可以看出, GPA分数的系数是显著的,对 ASP有正的影响。(2) 以ASP为因变量,GMAT为自变量做回归分析,结果如下:Dependent Variable: SER

35、01Method: Least SquaresDate; 07/03/09 Time: 13:07Sample: 1 30Included observations: 30VariableCoetficientStd. Error t-StatisticProbC-332306.847572.09-6.9053320.0000SERBS641.65987b. 150368 4262220 0000R-squared0.717175Mean dependent var6S260.00Adjusted R-squared0.707074S.D. dependent var18187.78S.IE.

36、 of regression9343.701Akaike info criterion21.29139Sum squared resid271E-KBSchwarz criterion21 38480Log likelihood-317.3709F-statistic71 00122Durbin-Watson stat1 120809Prob(F-statistic)0 000000从回归结果可以看出,GMAT分数与ASP是显著正相关的。(3) 以ASP为因变量,X为自变量进行回归分析,结果如下:Dependent Variable: SER01Method: Least SquaresDat

37、e: 073/08 Time: 13:09Sample: 1 30In eluded observatiors: 30VariableCoefficientStd. Error t-StatisticProb.C23126 329780.8632 3644460.0262SER042 6334630.5516014 7742520.0001R-squared0 448748Mean dependent var68260.00Adjusted R-squared0.429061S.D. dependent var18187.78S.E of regression13742 78Akaike in

38、fo criterion21.95876Sum squared resid5.29E-KJ9Schwarz criterion22 05217Log likelihood-327.3013F-statistic22.79348Durbin-Watson stat1 142178Prob(F-statistic)0 000051从回归结果可以看出,每年的学费与ASP显著正相关。学费高,ASP就高;但学费仅解释了 ASP变化的一部分,明显还有其他因素影响着ASP。(4)以GPA为因变量,X为自变量进行回归分析,结果如下:Dependent Variable: SER02 Melhod: Least

39、 Squares Date: 07AJMS Time: 13:14Sample: 1 30Included observations: 30VariableCoefficientStd Errcr t-StatisticProb.C3.147579007255943.379360.0000SER046.17E-064.09E-061.5079520.1428R-squared0.075112h/lean dependent var3.253333Adjusted R-squared0 042080S D dependent var0 104166S.E. of regression0.1019

40、51Akaike info criterion1.664311Sum squared nesid0.291032Schwarz criteirion1.570897Log likelihood26,96466F-statistic2.273920Durbin-Watson stat1.702756Prob(F-statistiic)0 142768从回归结果可以看出,尽管高学费的商业学校与高质量的MBA成绩略有正相关性,但学费对GPA分数的影响是不显著的,所以学费并不是影响GPA分数的主要原因。六、表2.6给出了 1988年9个工业国的名义利率(Y)与通货膨胀率(X)的数据。(1)以 利率为纵

41、轴,以通过膨胀率为横轴作图;(2)用OLS法进行回归分析;(3)如果实际利率不变,则名义利率与通货膨胀率的关系如何。表2.61988年九个工业国的名义利率与通货膨胀率国家Y/%X/%国家Y/%X/%澳大利亚11.97.7墨西哥66.351加拿大9.44瑞典2.22法国7.53.1英国10.36.8德国41.6美国7.64.4意大利11.34.8XSeries ListLi st of series, groups. aii4/or seri es escpresEiojisOKc-SERO2(1)作线图(2) 作OLS回归,结果如下:D即endent Variable: SER01Method

42、: Least SquaresOate: D7AJ3AJ日 Time: 13:37Sample: 1 9Included observations: 9VariableCoefficiientStd. Error t-StatisticPmb.C2.6361740 6913033.8133400.0066SERD21.2502860.03932631 7927J0.0000R-squared0.993122Mean dependent var14.50000Adjusted R-squared0.992140S.D. dependent var1969160S E. of regression

43、1.745010Akaike info criterion4 145445Sum squared resid21.33498Schwarz criterion4 189272Log likelihood16.65490F-statistic1010,778Durbin-Wats口n stat1.B1937EPrab(F-statistic)0 000000上述回归结果表明,如果实际利率不变,名义利率与通货膨胀率呈正向关系;斜率1.2503表明通货膨胀率上升 1个点,名义利率上升 1.25个点。七、根据表中提供的数据,试建立我国最终消费支出与国内生产总值(单位:亿元)之间的回归模型,并进行参数以

44、及总体的显著性检验。当:=0.05,X2002 =102398亿元时,对y2003进行预测。表2.71978-2001年中国最终消费支出与国内生产总值统计资料年份最终消费(y)国内生产总值(x)年份最终消费(y)国内生产总值(X)19782239.13624.1199011365.218547.919792619.44038.2199113145.921617.819802976.14517.8199215952.126638.119813309.14862.4199320182.134634.419823637.95294.7199426796.046759.419834020.55934.

45、5199533635.058478.119844694.57171.0199640003.967884.619855773.08964.4199743579.474462.619866542.010202.2199846405.978345.219877451.211962.5199949722.782067.519889360.114928.3200054616.789442.2198910556.516909.2200158952.695933.3资料来源:国家统计局中国统计年鉴2001.北京:中国统计出版社,2002(1)做散点图如下:从x与y的散点图可以看出,最终消费支出与国内生产总值

46、之间存在线性关系。因此 可设定最终消费支出 yt与国内生产总值 Xt的关系为yt = bobiXtut(2)根据模型设定进行线性回归,结果如下:Vie/-; Procl Object Print f-Jame Freeze Estimate Forecast: Stats ResidsDependent Variable: YMethod: Least SquaresDate: 10/20-09 Time:20:45Sample: 1978 2001Included ot)ser;atians: 24VariableCoefficientStd. Error(-StatisticFcobC199.815020455510976B270.3393X0 5959

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论