ggplot2中的上标和下标轴标签

时间:2014-12-12 14:10:49

标签: r ggplot2 axis-labels

我需要ggplot2中的轴标签,其中“同化(μmolCO2m-2 s-1)”,其中2的CO2为下标,-2和-1为上标。 感谢。

1 个答案:

答案 0 :(得分:73)

你可以尝试

library(ggplot2)
qplot(uptake, data = CO2) +
   xlab(bquote('Assimilation ('*mu~ 'mol' ~CO[2]~ m^-2~s^-1*')'))

enter image description here