Questions tagged [stargazer]

Stargazer is an R package that produces LaTeX code for well-formatted tables that hold regression analysis results from several models side-by-side, as well as summary statistics.

Stargazer is an package that produces code for well-formatted tables that hold regression analysis results from several models side-by-side, as well as summary statistics.

Repositories

Vignettes

588 questions
2
votes
2 answers

How do I create quantile regression tables using stargazer?

I computed the following quantile regressions using the quantreg package qr_10 = rq(inno_DELTA ~ deDomains + R_and_D_pc + Pop_dens + Agr_GDP + Manufacturing_GDP + Service_GDP + Infr_Area_Percent + Res_pc + Debt_GDP + GOV_EXP_GDP + firms_total +…
2
votes
1 answer

How to include number of groups from a panel regression (plm) in stargazer tables

Regression result tables are produced via stargazer from plm objects. Below in the summary part, only Oberservations, R², Adjusted R² and the F Statistic are presented. I would also like to include the number of groups and periods. These appear as…
Dima
  • 146
  • 1
  • 1
  • 12
2
votes
2 answers

Stargazer doesn't display basic stats (e.g. obs count, R2) when taking coeftest as argument

I am running a multivariate OLS regression using lmtest with two-way clustered standard errors. The coefficients and standard errors work perfectly, but the usual stats (e.g. number of observations, R2, adj. R2, Residual SE, F Statistic) are not…
barduco
  • 23
  • 3
2
votes
1 answer

Formatting multiple models on top of each other in stargazer

I want to format multiple univariate model outputs on top of one another using stargazer (with the same dependent variable), and I can't get them to not show up side-by-side. data(iris) stargazer(multinom(Species ~ Sepal.Length, data = iris), …
T.P.
  • 87
  • 1
  • 6
2
votes
1 answer

Stargazer output in RMarkdown - What is my illegal charachter?

I am running logistic regression models and try to print out the output with stargazer in RMarkdown. I have applied dcolumn in my setup, but I still get "! LaTeX Error: Illegal character in array arg." when I try to knit the document to a pdf. I…
2
votes
0 answers

Can stargazer output both SE and CI?

I am brand new to using R, but have discovered Stargazer as an attractive way to display regression output. My question is whether there is a way for Stargazer to output BOTH SE of coefficients and CI? I realize this may be statistically redundant,…
GreyGuy
  • 21
  • 1
2
votes
2 answers

Exponentiating CI in Stargazer

I am trying to run quite a few multinomial regression models. Stargazer seems like a great tool to report all results in one document for easy access. However, I noted that I get some negative confidence intervals, which does not make sense. I…
Saba
  • 21
  • 1
2
votes
1 answer

Visualizing multiple summaries with stargazer

I am currently working on a project where I am comparing multiple linear regressions. Stargazer does an amazing job with exporting summaries for the relevant model but I have been wondering if it was possible to implement a function in the stargazer…
P.Weyh
  • 97
  • 9
2
votes
2 answers

Estimating multiple `lm` models and returning output in one table, with map()

I need to estimate a number of linear models on the same dataset, and put the regression results all into one table. For a reproducible example, here's a simplification using mtcars: formula_1 = "mpg ~ disp" formula_2 = "mpg ~ log(disp)" formula_3 =…
Jeremy K.
  • 1,710
  • 14
  • 35
2
votes
1 answer

Reorder variables in stargazer

I got some problem when I was trying to reorder variables in stargazer. First, I defined a character vector indicating the order I want. > order [1] "poly(log(fall_t), 2)1" "poly(log(fall_t), 2)2" "poly(winter_t, 2)1" …
Yabin Da
  • 553
  • 5
  • 11
2
votes
2 answers

Rounding to 0 in Stargazer Summary Stats

I am trying to create a summary statistics table with Stargazer with some large variables (mean>1000) and some smaller ones (<1). The problem is that I don't want decimals on the larger numbers, only on the smaller ones. I tried using digits.extra,…
winitheju
  • 65
  • 1
  • 7
2
votes
4 answers

How do you insert greek symbols into stargazer labels within markdown?

I am trying to insert a greek delta into a covariate label within stargazer. I have tried \Delta but it returns an error about the escape character '\D'. I have attempted with '\', wrapping in '$' and on and on. What does work is to use the string…
Jeremy Cox
  • 61
  • 6
2
votes
1 answer

stargazer lme4 incompatible

I am using lmer from the lme4 package and lmerTest. My regression looks as follows: r1 <- lmer(a ~ b + c + as.factor(d) + (1 | e), data = df) I would like to use stargazer and used this code: stargazer(r1, type = "text") However, it doesn't work.…
Sean Burgess
  • 67
  • 1
  • 5
2
votes
1 answer

Stargazer in a bookdown site

I'm trying to show Stargazer tables (both for regressions and data summary) in a bookdown based website. stargazer output does not look like it looks in outside bookdown (i.e markdown/knitr/html). It has spaces between rows, rows are zebra striped…
letmetype
  • 105
  • 7
2
votes
1 answer

Stargazer one line per data set

I am running regressions using various subsets of a data set and a number of dependent variables. An example using attitude data: library(stargazer) #REGRESSIONS USING DATASET 1 linear1.1 <- lm(rating ~ complaints, data = attitude) #dependent…
yrx1702
  • 1,619
  • 15
  • 27