Stargazer Omit test statistics

匿名 (未验证) 提交于 2019-12-03 03:03:02

问题:

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 . Does anyone know how I might go about this?

For Example:

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.

回答1:

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.

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))

Update:

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*".



转载请标明出处:Stargazer Omit test statistics
标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!