楼主: wuyu0505
2178 3

[作图问题求助] stata制图问题 [推广有奖]

  • 0关注
  • 0粉丝

初中生

66%

还不是VIP/贵宾

-

威望
0
论坛币
0 个
通用积分
0
学术水平
0 点
热心指数
0 点
信用等级
0 点
经验
425 点
帖子
9
精华
0
在线时间
17 小时
注册时间
2012-9-13
最后登录
2014-5-21

+2 论坛币
k人 参与回答

经管之家送您一份

应届毕业生专属福利!

求职就业群
赵安豆老师微信:zhaoandou666

经管之家联合CDA

送您一个全额奖学金名额~ !

感谢您参与论坛问题回答

经管之家送您两个论坛币!

+2 论坛币
我的回归语句含义是差不多这样的 reg y x2 x a b c d.  abcd都是控制变量,
我想问下,怎么用stata来制图反映xy关系,编程是怎样的?

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

关键词:Stata tata 控制变量 ABCD 差不多 制图

沙发
wuyu0505 发表于 2013-3-29 18:51:58 |只看作者 |坛友微信交流群
x2是平方的意思,写的不是很好看,不要误会啊,大家帮一忙,是在是不清楚~~

使用道具

藤椅
蓝色 发表于 2013-3-30 00:47:44 |只看作者 |坛友微信交流群
Title

    reganat --   Graphical inspection of linear multivariate models


Syntax

        reganat depvar varlist [if] [in] [, options]

    options               Description
    ------------------------------------------------------------------------------------------------------------------
    Options
      dis(varlist)        graphs only the variables in varlist and omits the rest
      biline              plots a regression line for the bivariate linear model
      biscat              plots a scatterplot for the bivariate linear model
      reg                 displays the results for the estimation of the multivariate model
      nolegend            prevents the legend to be displayed
      nocovlist           prevents the list of covariates to be displayed
      scheme(scheme)      specifies the graphical scheme
    ------------------------------------------------------------------------------------------------------------------
    by is not allowed.


Description

    reganat is a graphical tool for inspecting the effect of a covariate on a dependent variable in the context of
    multivariate OLS estimation.  The name is an acronym for the expression regression anatomy, a result in OLS'
    algebra originally due to Frisch and Waugh (1933) and recently revived by Angrist and Pischke's Mostly Harmless
    Econometrics (2009).  In a bivariate regression model Y = bx1 + g, the graphical inspection of the scatterplot
    provides useful information on the relation between the independent variable x1 and the dependent variable Y, but
    can be highly misleading when the underlying real model is multivariate of the type Y = X'B + e where X' includes
    also x1.  In general, the OLS multivariate estimator is not equivalent to an OLS estimator obtained using a
    separate regression on each independent variable since correlation among independent variables must be accounted
    for.  Angrist and Pischke (2009) show that in a multivariable model, the regression parameter for a given
    regressor is the bivariate slope coefficient for the corresponding regressor after partialling out all other
    covariates.  Accordingly, this command displays a table of scatterplots, with the dependent variable plotted
    against the independent variable net of any linear correlation with the other independent variables.  This
    combined graph can be helpful when inspecting the data for outliers, nonlinearities, and other modelling issues.

Options

        +---------+
    ----+ Options +---------------------------------------------------------------------------------------------------

    dis(varlist) specifies that the sense only the covariates included in varlist will be plotted in the graph.
        Nonetheless, the other variables still work as controls.

    biline specifies that on the graph will also be displayed the fitted regression line for the linear model Y = x1 +
        g, where x1 is the variable of interest.

    biscat specifies that on the graph will also be displayed the scatterplot for (Y,x1), where x1 is the variable of
        interest.

    reg displays the numerical results for the estimation of the multivariate model Y = X'B + e.

    nolegend prevents the legend to be displayed.

    nocovlist prevents the list of covariates to be displayed.

    scheme(graphical scheme) can be used to specify the graphical scheme to be applied to the composite graph. By
        default, the command uses the sj scheme.

Examples

    Setup
        . sysuse auto, clear

    Obtain a combined graph of the effect of several regressors
        . reganat price length weight headroom mpg

    Obtain a combined graph of the effect of a subset of the regressors, along with scatterplots and fitted line for
    the univariate models
        . reganat price length weight headroom mpg, dis(weight length) biline

References

    Angrist, J. and Pischke, J. S. (2009) Mostly Harmless Econometrics. Princeton University Press.

    Frisch, R. and Waugh, F. W. (1933) Partial Time Regression as Compared with Individual Trends. Econometrica 1:
        387-401.

Acknowledgment

    The author wishes to express his deep gratitude to Joshua Angrist for a number of insights and advices which have
        greatly enhanced the scope and the reliability of this command.

Author

    Valerio Filoso, Department of Economics, University of Naples "Federico II", Italy.
    If you observe any problem, please mailto:filoso@unina.it.

使用道具

板凳
蓝色 发表于 2013-3-30 00:48:35 |只看作者 |坛友微信交流群
含平方项的不好说了

使用道具

您需要登录后才可以回帖 登录 | 我要注册

本版微信群
加好友,备注jltj
拉您入交流群

京ICP备16021002-2号 京B2-20170662号 京公网安备 11010802022788号 论坛法律顾问:王进律师 知识产权保护声明   免责及隐私声明

GMT+8, 2024-5-6 04:35