How do I change the code below to have:
- a subscript after the symbol (e.g. it would be $\alpha_R$, $\beta_R$, $\gamma_R$ in LaTeX)
- a space between the "log" and the symbol (tried putting a "~" as suggested, but it didn't work)
This is a mixture of the questions Plotting axis labels with Greek symbols from a vector and Subscripts in plots in R.
# vector of symbols to go in graphs
symbol_list <- c("alpha", "beta", "gamma");
set.seed(1234);
count <- 1;
for (symbol in symbol_list){
# random data
x <- runif(10, 0,1);
y <- runif(10, 0,1);
png(paste0("test",count,".png"));
# make graph with different symbol in x label at each iteration
plot(x,y, xlab=parse(text = paste("log *",symbol)));
dev.off();
count <- count+1;
}