Here was a tricky questions just sent to me:
I’m trying to get δ44/42Ca915a (‰) to look like δ44/42Ca915a (‰). I only need at this time to do the ylab. I tried using the code below from the blog.
I have tried plotting it in
boxplot(Ensisheim, ylim=c(-1.0,-0.4), col=”red”, ylab=expression(paste(delta^{
44/42}, “Ca (\u2030)”))
and as just
plot(x, y, ylab=expression(paste(delta^{
44/42}, “Ca (‰)”))).
Solution
It took a bit of trial and error, but I was able to work a solution thanks to posts at stackoverflow (here and here)
What’s happening?
A special note on margins
You noticed the code par(mar=c(5,6,5,5))I called above before I plotted my figure. This asks R to make the lefthand margin larger than the others. When using superscripts on the y-axis, I’ve found the top edge of the superscript character can sometimes get cut off when you save the pdf from R. Just in case, make extra room in the margins!
