全部版块 我的主页
论坛 计量经济学与统计论坛 五区 计量经济学与统计软件 Stata专版
19858 19
2020-02-11
求助,数据经过merge之后明明已经是面板数据,为什么在xtset id year 的时候,总是报错,提示“no; data are mi set
    Use mi xtset to set or query these data; mi xtset has the same syntax as xtset.”
附件列表
微信图片_20200211131723.jpg

原图尺寸 522.71 KB

微信图片_20200211131723.jpg

二维码

扫码加我 拉你入群

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

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

全部回复
2020-2-11 15:49:59
你若要问程序,永远附上相关资料 (请不要用截图);若附上资料,永远用 dataex 印出资料。
•        先 ssc install dataex (并见说明),将原始 Stata 资料中具有”代表性”的一部分资料列出,以供有意回答者实验之用,并能提供具体操作指令。
•        请参考说明 https://bbs.pinggu.org/thread-5048204-1-1.html
二维码

扫码加我 拉你入群

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

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

2020-2-11 19:37:04
黃河泉 发表于 2020-2-11 15:49
你若要问程序,永远附上相关资料 (请不要用截图);若附上资料,永远用 dataex 印出资料。
•        先 ssc  ...
不好意思,我重新上传我的数据如下:
复制代码
二维码

扫码加我 拉你入群

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

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

2020-2-11 23:11:12
Just  follow help manual:

Remarks

    If you have set your data with any of the above commands before you mi set them, there is no problem; the settings were automatically
    imported.  Once you mi set your data, however, you will discover that Stata's other set commands no longer work.  For instance, here is
    the result of typing stset on an mi set dataset:

        . stset ...
        no; data are mi set
            Use mi stset to set or query these data; mi stset has the same syntax as stset.

            Perhaps you did not type stset.  Some commands call stset to obtain information about the settings.  In that case, that command is
            not appropriate for running directly on mi data.  Use mi extract to select the data on which you want to run the command, which is
            probably m=0.
        r(119);

    Also, you might sometimes see an error like the one above when you give a command that depends on the data being set by one of Stata's
    other set commands.  In general, it is odd that you would be running such a command directly on mi data because what you will get will
    depend on the mi style of data.  Perhaps, however, you are using mi wide data, where the structure of the data more or less corresponds to
    the structure of non-mi data, or perhaps you have smartly specified the appropriate if statement to account for the mi style of data you
    are using.  In any case, the result might be

        . some_other_command
        no; data are mi set
            Use mi XXXset to set or query these data; mi XXXset has the same syntax as XXXset.

            Perhaps you did not type stset.  Some commands call stset to obtain information about the settings.  In that case, that command is
            not appropriate for running directly on mi data.  Use mi extract to select the data on which you want to run the command, which is
            probably m=0.
        r(119);

    Substitute one of the set commands listed above for XXXset, and then understand what just happened.  You correctly used mi XXXset to set
    your data, you thought your data were set, yet when you tried to use a command that depended on the data being XXXset, you received this
    error.

    If this happens to you, the solution is to use mi extract to obtain the data on which you want to run the command -- which is probably
    m=0, so you would type mi extract 0 -- and then run the command.
二维码

扫码加我 拉你入群

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

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

2020-2-12 08:07:42
liuliumuzi02 发表于 2020-2-11 19:37
不好意思,我重新上传我的数据如下:
这个例子没问题,请自己
复制代码
二维码

扫码加我 拉你入群

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

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

2020-5-26 22:08:16
您好!请问这个问题后来怎么解决的?我也遇到了这个问题
二维码

扫码加我 拉你入群

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

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

点击查看更多内容…
栏目导航
热门文章
推荐文章

说点什么

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群