title: How to pass an expression to a geom_text label in ggplot?
body: <p>I am attempting to pass an expression with subscript to a single <code>geom_text()</code> label in <code>ggplot</code>. Here is my code right now:</p>
  <pre><code>my_exp &lt;- expression('my_exp'[s][u][b])
  
  my_data &lt;- 
    data.frame(
      var_1 = c(&quot;a&quot;, &quot;b&quot;, &quot;c&quot;),
      var_2 = c(1, 2, 3)
    )
  
  my_data %&gt;%
    ggplot(aes(x = var_1, y = var_2))+
    geom_text(aes(label = var_1))
  </code></pre>
  <p>Here is the resulting plot:</p>
  <p><a href="https://i.stack.imgur.com/tRnwr.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/tRnwr.png" alt="[Here is the resulting plot][1]." /></a></p>
  <p>What I would like to do is replace the <code>var_1</code> value of <code>&quot;a&quot;</code> with the expression specified by <code>my_exp</code> and then have <code>geom_text()</code> evaluate that value as an expression, resulting in the subscript appearing on the ggplot.</p>