-
-
Notifications
You must be signed in to change notification settings - Fork 8k
Closed
Description
For some reason I can't get matplotlib
to write down the \approx
LaTeX symbol in a legend.
Here's a MWE:
import matplotlib.pyplot as plt
plt.scatter([0.5, 0.5], [0.5, 0.5], label='$U_{c} \approx %0.1f$' % 22)
#plt.scatter([0.5, 0.5], [0.5, 0.5], label='$U_{c} \simeq %0.1f$' % 22)
#plt.scatter([0.5, 0.5], [0.5, 0.5], label='$U_{c} \sim %0.1f$' % 22)
plt.legend(fancybox=True, loc='upper right', scatterpoints=1, fontsize=16)
plt.show()
Notice the first line will not show the \approx
character or the value after it but both \simeq
and \sim
work fine.
Metadata
Metadata
Assignees
Labels
No labels