stat_fit_glance
fits a model and returns a summary
"glance" of the model's statistics, using package 'broom'.
stat_fit_glance(mapping = NULL, data = NULL, geom = "null",
method = "lm", method.args = list(formula = y ~ x),
label.x.npc = "left", label.y.npc = "top", label.x = NULL,
label.y = NULL, position = "identity", na.rm = FALSE,
show.legend = FALSE, inherit.aes = TRUE, ...)
The aesthetic mapping, usually constructed with
aes
or aes_string
. Only needs
to be set at the layer level if you are overriding the plot defaults.
A layer specific dataset - only needed if you want to override the plot defaults.
The geometric object to use display the data
character.
list of arguments to pass to method
.
numeric
with range 0..1 or character.
Coordinates to be used for positioning the output, expressed in "normalized
parent coordinates" or character string. If too short they will be
recycled.
numeric
Coordinates (in data units) to be used
for absolute positioning of the output. If too short they will be recycled.
The position adjustment to use for overlapping points on this layer
a logical indicating whether NA values should be stripped before the computation proceeds.
logical. Should this layer be included in the legends?
NA
, the default, includes if any aesthetics are mapped. FALSE
never includes, and TRUE
always includes.
If FALSE
, overrides the default aesthetics, rather
than combining with them. This is most useful for helper functions that
define both data and aesthetics and shouldn't inherit behaviour from the
default plot specification, e.g. borders
.
The output of glance
is
returned as is in the data
object.