Hello everyone
I need help to finish some hist3D plots using plot3D package.
The problem is that I don't know how to include superscripts and subscripts in the axis names of this kind of plots. I've tried several codes posted in this website but anyone works on hist3D plot.
I have this example:
library(plot3D)
VV <- volcano[seq(1, 87, 15), seq(1, 61, 15)]
hist3D(z = VV, scale = F, expand = 0.02, border = "black")
# And I want to include the axis names as follow:
# xlab = "NH4 (mg L-1)" ## The number 4 has to be subscript and -1 has to be superscript
# ylab = "Irradiance (mu mol m^2 s^-1)" ## 2 and -1 have to be superscripts
# zlab = "Concentration (g L^-1)" ## -1 has to be superscript
# I've tried the following codes but anyone works:
hist3D(z = VV, scale = F, expand = 0.02, border = "black", xlab = expression( "NH[4] (mg L"^-1)),
ylab = expression("Irradiance (mu mol m"^2 "s"^-1)), zlab = expression("Concentration (g L"^-1)))
hist3D(z = VV, scale = F, expand = 0.02, border = "black", xlab = expression(paste("NH[4] (mg L"^-1))),
ylab = expression(paste("Irradiance (mu mol m"^2 "s"^-1))), zlab = expression(paste("Concentration (g L"^-1))))
If somebody knows how to fix this problem I will appreciate it a lot