Description Usage Arguments Value See Also Examples

You can set the default values of most arguments of `coefplot`

with this function.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 | ```
setFixest_coefplot(
style,
horiz = FALSE,
dict = getFixest_dict(),
keep,
ci.width = "1%",
ci_level = 0.95,
pt.pch = 20,
pt.bg = NULL,
cex = 1,
pt.cex = cex,
col = 1:8,
pt.col = col,
ci.col = col,
lwd = 1,
pt.lwd = lwd,
ci.lwd = lwd,
ci.lty = 1,
grid = TRUE,
grid.par = list(lty = 3, col = "gray"),
zero = TRUE,
zero.par = list(col = "black", lwd = 1),
pt.join = FALSE,
pt.join.par = list(col = pt.col, lwd = lwd),
ci.join = FALSE,
ci.join.par = list(lwd = lwd, col = col, lty = 2),
ci.fill = FALSE,
ci.fill.par = list(col = "lightgray", alpha = 0.5),
ref.line = "auto",
ref.line.par = list(col = "black", lty = 2),
lab.cex,
lab.min.cex = 0.85,
lab.max.mar = 0.25,
lab.fit = "auto",
xlim.add,
ylim.add,
sep,
bg,
group = "auto",
group.par = list(lwd = 2, line = 3, tcl = 0.75),
main = "Effect on __depvar__",
value.lab = "Estimate and __ci__ Conf. Int.",
ylab = NULL,
xlab = NULL,
sub = NULL,
reset = FALSE
)
getFixest_coefplot()
``` |

`style` |
A character scalar giving the style of the plot to be used. You can set styles with the function |

`horiz` |
A logical scalar, default is |

`dict` |
A named character vector or a logical scalar. It changes the original variable names to the ones contained in the |

`keep` |
Character vector. This element is used to display only a subset of variables. This should be a vector of regular expressions (see |

`ci.width` |
The width of the extremities of the confidence intervals. Default is |

`ci_level` |
Scalar between 0 and 1: the level of the CI. By default it is equal to 0.95. |

`pt.pch` |
The patch of the coefficient estimates. Default is 1 (circle). |

`pt.bg` |
The background color of the point estimate (when the |

`cex` |
Numeric, default is 1. Expansion factor for the points |

`pt.cex` |
The size of the coefficient estimates. Default is the other argument |

`col` |
The color of the points and the confidence intervals. Default is 1 ("black"). Note that you can set the colors separately for each of them with |

`pt.col` |
The color of the coefficient estimates. Default is equal to the other argument |

`ci.col` |
The color of the confidence intervals. Default is equal to the other argument |

`lwd` |
General line with. Default is 1. |

`pt.lwd` |
The line width of the coefficient estimates. Default is equal to the other argument |

`ci.lwd` |
The line width of the confidence intervals. Default is equal to the other argument |

`ci.lty` |
The line type of the confidence intervals. Default is 1. |

`grid` |
Logical, default is |

`grid.par` |
List. Parameters of the grid. The default values are: |

`zero` |
Logical, default is |

`zero.par` |
List. Parameters of the zero-line. The default values are |

`pt.join` |
Logical, default is |

`pt.join.par` |
List. Parameters of the line joining the coefficients. The default values are: |

`ci.join` |
Logical default to |

`ci.join.par` |
A list of parameters to be passed to |

`ci.fill` |
Logical default to |

`ci.fill.par` |
A list of parameters to be passed to |

`ref.line` |
Logical or numeric, default is "auto", whose behavior depends on the situation. It is |

`ref.line.par` |
List. Parameters of the vertical line on the reference. The default values are: |

`lab.cex` |
The size of the labels of the coefficients. Default is missing. It is automatically set by an internal algorithm which can go as low as |

`lab.min.cex` |
The minimum size of the coefficients labels, as set by the internal algorithm. Default is 0.85. |

`lab.max.mar` |
The maximum size the left margin can take when trying to fit the coefficient labels into it (only when |

`lab.fit` |
The method to fit the coefficient labels into the plotting region (only when |

`xlim.add` |
A numeric vector of length 1 or 2. It represents an extension factor of xlim, in percentage. Eg: |

`ylim.add` |
A numeric vector of length 1 or 2. It represents an extension factor of ylim, in percentage. Eg: |

`sep` |
The distance between two estimates – only when argument |

`bg` |
Background color for the plot. By default it is white. |

`group` |
A list, default is missing. Each element of the list reports the coefficients to be grouped while the name of the element is the group name. Each element of the list can be either: i) a character vector of length 1, ii) of length 2, or ii) a numeric vector. If equal to: i) then it is interpreted as a pattern: all element fitting the regular expression will be grouped (note that you can use the special character "^^" to clean the beginning of the names, see example), if ii) it corrsponds to the first and last elements to be grouped, if iii) it corresponds to the coefficients numbers to be grouped. If equal to a character vector, you can use a percentage to tell the algorithm to look at the coefficients before aliasing (e.g. |

`group.par` |
A list of parameters controlling the display of the group. The parameters controlling the line are: |

`main` |
The title of the plot. Default is |

`value.lab` |
The label to appear on the side of the coefficient values. If |

`ylab` |
The label of the y-axis, default is |

`xlab` |
The label of the x-axis, default is |

`sub` |
A subtitle, default is |

`reset` |
Logical, default is |

Doesn't return anything.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | ```
# coefplot has many arguments, which makes it highly flexible.
# If you don't like the default style of coefplot. No worries,
# you can set *your* default by using the function
# setFixest_coefplot()
# Estimation
est = feols(Petal.Length ~ Petal.Width + Sepal.Length +
Sepal.Width | Species, iris)
# Plot with default style
coefplot(est)
# Now we permanently change some arguments
dict = c("Petal.Length"="Length (Petal)", "Petal.Width"="Width (Petal)",
"Sepal.Length"="Length (Sepal)", "Sepal.Width"="Width (Sepal)")
setFixest_coefplot(ci.col = 2, pt.col = "darkblue", ci.lwd = 3,
pt.cex = 2, pt.pch = 15, ci.width = 0, dict = dict)
# Tadaaa!
coefplot(est)
# To reset to the default settings:
setFixest_coefplot()
coefplot(est)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.