Variable in italic for plot title
Here is an example how to plot a title in italic using a variable.
layout(1)
i <- "Caretta caretta"
plot(1, main=substitute(expr = paste("Species name: ", italic(i)),
env = list(i=i)))
layout(1)
i <- "Caretta caretta"
plot(1, main=substitute(expr = paste("Species name: ", italic(i)),
env = list(i=i)))
Or simpler:
i <- "Caretta caretta"
plot(1, main=bquote("Species name: "*italic(.(i))))
i <- "Caretta caretta"
plot(1, main=bquote("Species name: "*italic(.(i))))
Commentaires
Enregistrer un commentaire