I have this code and I am trying to only make part of the string bold, not the entire legend string. How can I do that?
I have tried using "\033[1m" (start) and "\033[0;0m" (end) as well as plt.legend(prop=dict(weight='bold'), but again, this is making bold the entire string, but just part of it. Here is an example:
import matplotlib
import matplotlib.pyplot as plt
plt.plot([1,2,3], [4,5,6])
plt.legend(['Test [bold]'])
plt.show()
Inside the second set of brackets, I want 'bold' to actually be bold, not Test. Thanks