title: How to include greek letters and bold characters in a legend using plotly?
body: <p>I am trying to make a graph with greek letters in the legend and bold characters in the legend of the x-axis. This works fine with ggplot:</p>
  
  <pre><code>library(ggplot2)
  library(plotly)
  ## Dataframe
  df &lt;- data.frame(dose=c("D0.5", "D1", "D2"),len=c(4.2, 10, 29.5))
  
  ## Legend with the greek letter pi
  my.labs &lt;- list(bquote(Pi==.(5)) )
  
  ## Plot with ggplot
  p=ggplot(data=df, aes(x=dose, y=len, group=1,colour = paste("Pi = ",5,sep=""))) +
  geom_line()+
  geom_point()+
  scale_colour_manual(values=3, labels=my.labs)+
  theme(legend.title=element_blank(), legend.position = c(.1, .9),axis.title.x = element_text(face="bold", colour="black", size=10))
  
  p
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/VRDoB.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/VRDoB.png" alt="Graph with ggplot"></a></p>
  
  <p>However the greek letter and the bold legend for the x-axis disappear when using plotly:</p>
  
  <pre><code>p=plotly_build(p)
  style( p, hoverinfo = "x+y" ) %&gt;% 
  layout( legend = list(x = 0.1, y = 0.9, font=list(size=12)) )
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/3GWUp.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/3GWUp.png" alt="Same graph using plotly"></a></p>