在不带乳胶的matplotlib方程标签中使用特殊字符\ ddagger

时间:2018-08-31 23:49:17

标签: python matplotlib latex

正如标题所说,我想在标题和标签方程式中使用matplotlib方程式渲染(而不是通过rc选项切换到乳胶渲染),因为它速度更快,而且我喜欢字体和样式。但是,它似乎不支持$ \ ddagger $符号。我收到错误消息:

Unknown symbol: \ddagger (at char 31), (line:1, col:32)
有趣的是,所有其他符号也一样,\ dagger也起作用。任何帮助将不胜感激。

1 个答案:

答案 0 :(得分:1)

\ddagger符号具有Unicode 2021。因此,使用STIX字体集(查找所有符号here的表),您应该可以将其写为

ax.set_title(u"\ddagger $\u2021$")

enter image description here