p <- ggplot(mtcars, aes(x = cyl, y = mpg)) +
geom_point(shape = 1) +
labs(title = "Fuel Efficiency by Engine Type",
subtitle = "Larger engines are less efficient",
caption = "Source: Motor Trend",
x = "Number of Cylinders",
y = "Fuel Efficiency (MPG)")
gg_remove_titles(plot = p)
Run the code above in your browser using DataLab