I'm wondering how I can replace the multiplication sign (i.e., x) with its ASCII code (Alt 0215
) in my current text()
code in R below?
NOTE: If you know of any code other than ASCII for the multiplication sign (i.e., x) that is compatible with Shiny
that would be OK.
Here is my R code:
G1 = 1
G2 = 2
type = 1
plot(1:10, ty = "n", ann = F, bty = "n")
text(6, 6,
bquote(paste("GG = ", frac(.(G1), .(G2)),
.(ifelse(type == 1, " × 2", "")), ## HERE is where I need to use the ASCII code for "×"
" = ",
.(ifelse(type == 1, G1/G2 * 2, G1/G2)), sep = "")),
col = "red4", cex = 1.6)