View source: R/geom_line_endpoint.R
geom_line_endpoint | R Documentation |
add a charming endpoint to your lines
geom_line_endpoint(
mapping = NULL,
data = NULL,
position = "identity",
na.rm = FALSE,
show.legend = NA,
inherit.aes = TRUE,
...
)
... |
# functions
geom_line_endpoint
library(ggplot2)
ggplot(cars) +
aes(x = speed, y = dist) +
geom_line() +
geom_line_endpoint()
ggplot(cars) +
aes(x = speed, y = dist, color = dist > 15) +
geom_line() +
geom_line_endpoint()
ggplot(cars) +
aes(x = speed, y = dist,
color = dist > 15,
linetype = speed > 16) +
geom_line() +
geom_line_endpoint()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.