我已经成功地复制了这些图表:
http://matplotlib.org/xkcd/examples/showcase/xkcd.html
但是我的字体看起来不像那样。如何将文本字体更改为酷炫的xkcd字体?
我已经成功地复制了这些图表:
http://matplotlib.org/xkcd/examples/showcase/xkcd.html
但是我的字体看起来不像那样。如何将文本字体更改为酷炫的xkcd字体?
引用>>> help(plot.xkcd)
的输出:
For best results, the "Humor Sans" font should be installed: it is
not included with matplotlib.
sudo fc-cache -f -v
命令以刷新字体缓存
现在字体可以使用了。%userprofile%\.matplotlib
Ubuntu:~/.cache/matplotlib
- bastelflp
matplotlib
版本到1.4.0
。这个版本包括xkcd
。从示例中生成的图表采用xkcd
风格,并且效果非常好。 - The Dude