title | R Documentation |
Adds a title to the plot. See title
for more details.
title(object, ...)
object |
gsplot object |
... |
Further graphical parameters may also be supplied as arguments. See 'Details'. |
Additional graphical parameter inputs:
main
character string that goes above the plot
sub
character string that goes below the plot
col.main, col.sub
color for the main title and subtitle, respectively
font.main, font.sub
numeric value specifying the font style (1=normal, 2=bold, 3=italic, 4=bold and italic)
cex.main, cex.sub
numeric value specifying the size of the main title and subtitle
title
gs <- gsplot() %>%
points(y=1, x=2, col="blue", pch=18, legend.name="Points", xlab="Stuff") %>%
lines(c(3,4,3), c(2,4,6), legend.name="Lines", ylab="Data!") %>%
abline(b=1, a=0, legend.name="1:1") %>%
legend(location="topleft",title="Awesome!") %>%
title(main="Great Graph", col.main="grey", font.main=2, cex.main=2)
gs
gs <- gsplot() %>%
points(y=1, x=2) %>%
title(main="Great Graph")
gs
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.