占星仪省略测试统计 [英] Stargazer Omit test statistics

查看:172
本文介绍了占星仪省略测试统计的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

使用stargazer时有一个参数omit.stat,但是我需要从系数值下方删除测试统计信息,它不是

When using stargazer there is an argument, omit.stat, however I need to remove the test statistics from below my coefficient values and it isn't an argument listed in the stargazer package documentation (PDF) (pp. 14–15). Does anyone know how I might go about this?

例如:

install.packages('stargazer'); library(stargazer)
linear.1 <- lm(rating ~ complaints + privileges + learning + raises + critical,
               data=attitude)
linear.2 <- lm(rating ~ complaints + privileges + learning, data=attitude)
attitude$high.rating <- (attitude$rating > 70)
probit.model <- glm(high.rating ~ learning + critical + advance,
                    data=attitude, family = binomial(link = "probit"))

stargazer(linear.1, linear.2, probit.model, title="Regression Results",
          align=TRUE, dep.var.labels=c("Overall Rating","High Rating"),
          covariate.labels=c("Handling of Complaints","No Special Privileges",
          "Opportunity to Learn","Performance-Based Raises","Too Critical",
          "Advancement"), omit.stat=c("LL","ser","f"), no.space=TRUE)

以上内容为我提供了带有测试统计信息的表格,我希望将其完全省略.以下内容将其替换为置信区间,但这并没有更好的效果.

The above gives me a table with test statistics, which I would like to omit entirely. The following replaces them with confidence intervals but that isn't any better.

stargazer(linear.1, linear.2, title="Regression Results",
dep.var.labels=c("Overall Rating","High Rating"),
covariate.labels=c("Handling of Complaints","No Special Privileges",
                   "Opportunity to Learn","Performance-Based Raises",
                   "Too Critical","Advancement"), omit.stat=c("LL","ser","f"),
                   ci=TRUE, ci.level=0.90, single.row=TRUE)

可以在

The tables can be seen on the R-statistics blog entry, Tailor Your Tables with stargazer: New Features for LaTeX and Text Output, as the first and second respectively.

推荐答案

当前版本的stargazer不支持省略标准错误和/或置信区间(我认为这就是测试统计信息"的意思).但是,我一直在考虑在以后的发行版中使观星者的输出更加可调-随时向我(软件包作者)发送有关如何最好地做到这一点的想法.

The current version of stargazer does not support omitting the standard errors and/or confidence intervals (I assume this is what you mean by 'test statistics'). However, I have been considering making stargazer output a lot more adjustable in future releases - feel free to send me (the package author) ideas about how best to do this.

就目前而言,一种忽略标准错误的骇人听闻的方法可能涉及向se参数提供NA列表:

For now, a hackish way to omit standard errors might involve feeding the se argument a list of NAs:

stargazer(linear.1, linear.2, probit.model, title="Regression Results", 
align=TRUE, dep.var.labels=c("Overall Rating","High Rating"), 
covariate.labels=c("Handling of Complaints","No Special Privileges", 
"Opportunity to Learn","Performance-Based Raises","Too Critical","Advancement"),
omit.stat=c("LL","ser","f"), no.space=TRUE, se=list(NA, NA, NA))

更新:

从5.0版开始,stargazer包含了"report"参数,该参数允许用户选择要报告的统计信息.例如,要仅报告具有重要星号的系数,用户可以指定report = "c*".

Since version 5.0, stargazer has included the 'report' argument that allows users to choose which statistics to report. To report only coefficients with significance stars, for instance, users can specify report = "c*".

这篇关于占星仪省略测试统计的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆