Referring to this question thread Matplotlib: Italic style in regular font, I'm not able to achieve the same results with the latest python version 3.9.13 (I can achieve this previously).
I want to label the x-axis as the displacement in Angstrom mathsymbol with the same Times New Roman font in italic style.
plt.rcParams['mathtext.fontset'] = 'stix'
plt.xlabel("Displacement ($\mathregular{\mathit{\AA}}$)",fontname="Times New Roman",fontsize=12)
I can obtain the Angstrom symbol in italic style, but not same Times New Roman fontstyle (Even though I have applied the mathtext fontset stix). If I try this:
plt.xlabel("Displacement ($\mathregular{\AA}$)",fontname="Times New Roman",fontsize=12)
I can obtain the Angstrom symbol in Times New Roman, but not in Italic style... What should I change to achieve this? Thanks
Picture of x-label: