Closed etiennebacher closed 5 months ago
Hi Etienne, actually in most setFixest_*
functions, there is the argument reset
:
setFixest_etable(
style.df = style.df(
fixef.suffix = " fixed effect",
yesNo = "Yes"
)
)
res = feols(Sepal.Length ~ Sepal.Width | Species, iris)
etable(res)
#> the previous table
# getting the default style back
setFixest_etable(reset = TRUE)
etable(res)
#> res
#> Dependent Var.: Sepal.Length
#>
#> Sepal.Width 0.8036** (0.0714)
#> Fixed-Effects: -----------------
#> Species Yes
#> _______________ _________________
#> S.E.: Clustered by: Species
#> Observations 150
#> R2 0.72591
#> Within R2 0.28115
#> ---
#> Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
# You can also add options when using reset
setFixest_etable(reset = TRUE, digits = 2)
etable(res)
#> res
#> Dependent Var.: Sepal.Length
#>
#> Sepal.Width 0.80** (0.07)
#> Fixed-Effects: -------------
#> Species Yes
#> _______________ _____________
#> S.E.: Clustered by: Species
#> Observations 150
#> R2 0.72591
#> Within R2 0.28115
#> ---
#> Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Isn't that enough for the purpose?
Well I guess I should just improve my RTFM skills :sweat_smile: thanks!
The
setFixest_*
functions are extremely helpful to avoid duplicating the same options again and again. However, sometimes I want to remove some general options that I wrongly put insetFixest_*
earlier. The problem is that (if I'm not mistaken) the only way to do so is to restart the session and set the correct options. This can be annoying because I would need to redo some computations.Is it possible to have something like
fixest::reset_options(type = c("table", "coefplot", ...))
where one can reset all options set insetFixest_*
to their default?As always, thanks for this amazing package.
Small example: