Description Usage Arguments Value See Also Examples
View source: R/addggregression.R
Add a regression or loess to an existing ggplot
1 2 | addggregression(myplot, doregression = T, doloess = F, span = if (doloess
== T) { c(0.5, 1, 1.5, 2) }, colour = "black", ...)
|
myplot |
The ggplot object that wants to be annotated with a regression |
Returns the pots with the additions
ggdotscolor
1 2 3 4 | x=rnomr(1,1,100)
y=rnorm(1,2,100)
x=rnorm(1,3,100)
ggdotscolor(x=x,y=y,colorvar=z) %>% addggregression()
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.