Build ggplot object for coefplot
buildPlotting.default(modelCI, title = "Coefficient Plot", xlab = "Value",
ylab = "Coefficient", lwdInner = 1, lwdOuter = 0, pointSize = 3,
color = "blue", cex = 0.8, textAngle = 0, numberAngle = 0,
shape = 16, linetype = 1, outerCI = 2, innerCI = 1, multi = FALSE,
zeroColor = "grey", zeroLWD = 1, zeroType = 2, numeric = FALSE,
fillColor = "grey", alpha = 1/2, horizontal = FALSE, facet = FALSE,
scales = "free", value = "Value", coefficient = "Coefficient",
errorHeight = 0, dodgeHeight = 1)
An object created by buildModelCI
The name of the plot, if NULL then no name is given
The x label
The y label
The thickness of the inner confidence interval
The thickness of the outer confidence interval
Size of coefficient point
The color of the points and lines
The text size multiplier, currently not used
The angle for the coefficient labels, 0 is horizontal
The angle for the value labels, 0 is horizontal
The shape of the points
The linetype of the error bars
How wide the outer confidence interval should be, normally 2 standard deviations. If 0, then there will be no outer confidence interval.
How wide the inner confidence interval should be, normally 1 standard deviation. If 0, then there will be no inner confidence interval.
logical; If this is for multiplot
then leave the colors as determined by the legend, if FALSE then make all colors the same
The color of the line indicating 0
The thickness of the 0 line
The type of 0 line, 0 will mean no line
logical; If true and factors has exactly one value, then it is displayed in a horizontal graph with continuous confidence bounds.
The color of the confidence bounds for a numeric factor
The transparency level of the numeric factor's confidence bound
logical; If the plot should be displayed horizontally
logical; If the coefficients should be faceted by the variables, numeric coefficients (including the intercept) will be one facet
The way the axes should be treated in a faceted plot. Can be c("fixed", "free", "free_x", "free_y")
Name of variable for value metric
Name of variable for coefficient names
Height of error bars
Amount of vertical dodging
a ggplot graph object
This function builds up the ggplot layer by layer for coefplot.lm
# NOT RUN {
data(diamonds)
model1 <- lm(price ~ carat + cut, data=diamonds)
theCI <- coefplot:::buildModelCI(model1)
coefplot:::buildPlotting.default(theCI)
coefplot(model1)
# }
Run the code above in your browser using DataLab