加载中…
个人资料
  • 博客等级:
  • 博客积分:
  • 博客访问:
  • 关注人气:
  • 获赠金笔:0支
  • 赠出金笔:0支
  • 荣誉徽章:
正文 字体大小:

Stata:合成控制法-synth-命令无法加载-plugin-的解决办法

(2020-07-24 19:32:59)
分类: 内生性专题
原文链接:https://www.lianxh.cn/news/d7c94c7777226.html

目录


合成控制法的常用命令 synth 在使用过程中,可能会出现一些问题,导致命令无法正常运行。本文列出两种经常出现的问题,并给出解决方案。

1. 第一种出现的报错

运行 synth 命令以后,显示无法加载 synthopt.plugin 

  use "smoking.dta",clear
  xtset state year
  
  synth cigsale  lnincome age15to24 retprice beer(1984(1)1988) ///
            cigsale(1988) cigsale(1980) cigsale(1975),             ///
            trunit(3) trperiod(1989) xperiod(1980(1)1988)          ///
                fig nested allopt
*===================== 出现下面报错信息 ======================*
Could not load plugin: D:\stata15/ado\plus\s\synthopt.plugin
(error occurred while loading synth.ado)
r(9999);

这是旧版本文件可能存在的问题,如果电脑里面装了多个版本的 synth 命令相关文件,可能会导致错误调用。

解决方案: 使用 ssc install synth, replace 更新 synth 命令。

. ssc install synth, replace

*========================== 显示结果如下: ========================
the following files will be replaced:
    D:\stata15/ado\plus\s\synth.sthlp
    D:\stata15/ado\plus\s\synthopt.plugin

installing into D:\stata15/ado\plus\...
installation complete.

0

阅读 收藏 喜欢 打印举报/Report
  

新浪BLOG意见反馈留言板 欢迎批评指正

新浪简介 | About Sina | 广告服务 | 联系我们 | 招聘信息 | 网站律师 | SINA English | 产品答疑

新浪公司 版权所有