View source: R/stat_cooks_leverage.R
stat_cooks_leverage | R Documentation |
Cook's Distance vs. Leverage
stat_cooks_leverage(
alpha = 0.5,
method = "loess",
color = "steelblue",
se = FALSE,
...
)
alpha |
Adjust transparency of points. |
method |
Method for fitting the line to the points. |
color |
Color of the line. |
se |
Keep standard error bands around line? |
... |
Currently ignored. For extendability. |
A ‘ggplot2' layer for plotting Cook’s Distance vs. Leverage.
data(mtcars)
model <- lm(mpg ~ cyl + disp + hp, data = mtcars)
ggplot2::ggplot(data = model) + stat_cooks_leverage()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.