I am trying to evaluate a variable inside theexpression
function. The function works fine when the variable has no value and is just a string.
> plot(rnorm(30), xlab = expression(value~2^-dCT))
But when value is a variable, the value of the variable gets ignored...
> rm(value)
> value = "some text"
> plot(rnorm(30), xlab = expression(value~2^-dCT))
I also tried > plot(rnorm(30), xlab = expression(eval(value)~2^-dCT))
and had a similar issue...
plot(rnorm(30), xlab = expression(paste(value~2^-dCT)))
does not work as well. Any help would be appreciated, thank you!