Andy Davidson
2016-08-22 03:33:47 UTC
I am having a heck of a time figuring out how to use emojiâs in labels. I am
using python3 on a Mac and matplotlib 1.5.2
The unicode demo works.
http://matplotlib.org/examples/pylab_examples/tex_unicode_demo.html I think
my issue might have to do with fonts?
I found a discussion about emojis and fonts at
http://stackoverflow.com/questions/30049760/emoji-in-matplotlib-figures-on-o
s-x
They suggest adding the following line
prop = fm.FontProperties(fname='/System/Library/Fonts&#ââ47;Apple\ Color\
Emoji.ttf')matplotlib.rcParams['font.family'] = prop.get_name()
How ever I get the following error
/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-package
s/matplotlib/font_manager.py in get_name(self)
735 properties.
736 """
--> 737 return ft2font.FT2Font(findfont(self)).family_name
738
739 def get_style(self):
RuntimeError: In FT2Font: Could not set the fantasize
Here is what my graph looks like if I follow the âtex unicode demo'
Also I have about 21 different âcategories / factorsâ any suggestions how
to format the graph so the legend looks nice? Notice the colors are reused
and the legend is to bit
Thanks in advance
Andy
Log message:
DEBUG:root:AEDWIP pwsPlotDate() label: â
DEBUG:root:AEDWIP pwsPlotDate() label: â
DEBUG:root:AEDWIP pwsPlotDate() label: â
DEBUG:root:AEDWIP pwsPlotDate() label: â
DEBUG:root:AEDWIP pwsPlotDate() label: âª
DEBUG:root:AEDWIP pwsPlotDate() label: â€
DEBUG:root:AEDWIP pwsPlotDate() label: ð»
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ðŠ
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ð¿
DEBUG:root:AEDWIP pwsPlotDate() label: ð¥
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ðœ
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ð«
DEBUG:root:AEDWIP pwsPlotDate() label: ð
using python3 on a Mac and matplotlib 1.5.2
The unicode demo works.
http://matplotlib.org/examples/pylab_examples/tex_unicode_demo.html I think
my issue might have to do with fonts?
I found a discussion about emojis and fonts at
http://stackoverflow.com/questions/30049760/emoji-in-matplotlib-figures-on-o
s-x
They suggest adding the following line
prop = fm.FontProperties(fname='/System/Library/Fonts&#ââ47;Apple\ Color\
Emoji.ttf')matplotlib.rcParams['font.family'] = prop.get_name()
How ever I get the following error
/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/site-package
s/matplotlib/font_manager.py in get_name(self)
735 properties.
736 """
--> 737 return ft2font.FT2Font(findfont(self)).family_name
738
739 def get_style(self):
RuntimeError: In FT2Font: Could not set the fantasize
Here is what my graph looks like if I follow the âtex unicode demo'
Also I have about 21 different âcategories / factorsâ any suggestions how
to format the graph so the legend looks nice? Notice the colors are reused
and the legend is to bit
Thanks in advance
Andy
Log message:
DEBUG:root:AEDWIP pwsPlotDate() label: â
DEBUG:root:AEDWIP pwsPlotDate() label: â
DEBUG:root:AEDWIP pwsPlotDate() label: â
DEBUG:root:AEDWIP pwsPlotDate() label: â
DEBUG:root:AEDWIP pwsPlotDate() label: âª
DEBUG:root:AEDWIP pwsPlotDate() label: â€
DEBUG:root:AEDWIP pwsPlotDate() label: ð»
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ðŠ
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ð¿
DEBUG:root:AEDWIP pwsPlotDate() label: ð¥
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ðœ
DEBUG:root:AEDWIP pwsPlotDate() label: ð
DEBUG:root:AEDWIP pwsPlotDate() label: ð«
DEBUG:root:AEDWIP pwsPlotDate() label: ð