---------------------------------------------------------------------------
FileNotFoundError Traceback (most recent call last)
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\matplotlib\font_manager.py in <module>()
1352 try:
-> 1353 fontManager = json_load(_fmcache)
1354 if (not hasattr(fontManager, '_version') or
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\matplotlib\font_manager.py in json_load(filename)
887 """
--> 888 with open(filename, 'r') as fh:
889 return json.load(fh, object_hook=_json_decode)
FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\cmoha\\.matplotlib\\fontlist-v300.json'
During handling of the above exception, another exception occurred:
TypeError Traceback (most recent call last)
<ipython-input-1-6bff2b729802> in <module>()
----> 1 get_ipython().magic('matplotlib inline')
2 from copy import deepcopy
3 import numpy as np
4 import pandas as pd
5 from matplotlib import pyplot as plt
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\IPython\core\interactiveshell.py in magic(self, arg_s)
2161 magic_name, _, magic_arg_s = arg_s.partition(' ')
2162 magic_name = magic_name.lstrip(prefilter.ESC_MAGIC)
-> 2163 return self.run_line_magic(magic_name, magic_arg_s)
2164
2165 #-------------------------------------------------------------------------
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\IPython\core\interactiveshell.py in run_line_magic(self, magic_name, line)
2082 kwargs['local_ns'] = sys._getframe(stack_depth).f_locals
2083 with self.builtin_trap:
-> 2084 result = fn(*args,**kwargs)
2085 return result
2086
<decorator-gen-107> in matplotlib(self, line)
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\IPython\core\magic.py in <lambda>(f, *a, **k)
191 # but it's overkill for just that one bit of state.
192 def magic_deco(arg):
--> 193 call = lambda f, *a, **k: f(*a, **k)
194
195 if callable(arg):
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\IPython\core\magics\pylab.py in matplotlib(self, line)
98 print("Available matplotlib backends: %s" % backends_list)
99 else:
--> 100 gui, backend = self.shell.enable_matplotlib(args.gui)
101 self._show_matplotlib_backend(args.gui, backend)
102
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\IPython\core\interactiveshell.py in enable_matplotlib(self, gui)
2949 gui, backend = pt.find_gui_and_backend(self.pylab_gui_select)
2950
-> 2951 pt.activate_matplotlib(backend)
2952 pt.configure_inline_support(self, backend)
2953
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\IPython\core\pylabtools.py in activate_matplotlib(backend)
293 matplotlib.rcParams['backend'] = backend
294
--> 295 import matplotlib.pyplot
296 matplotlib.pyplot.switch_backend(backend)
297
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\matplotlib\pyplot.py in <module>()
30 from cycler import cycler
31 import matplotlib
---> 32 import matplotlib.colorbar
33 import matplotlib.image
34 from matplotlib import rcsetup, style
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\matplotlib\colorbar.py in <module>()
30 import matplotlib.collections as collections
31 import matplotlib.colors as colors
---> 32 import matplotlib.contour as contour
33 import matplotlib.cm as cm
34 import matplotlib.gridspec as gridspec
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\matplotlib\contour.py in <module>()
16 import matplotlib.colors as mcolors
17 import matplotlib.collections as mcoll
---> 18 import matplotlib.font_manager as font_manager
19 import matplotlib.text as text
20 import matplotlib.cbook as cbook
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\matplotlib\font_manager.py in <module>()
1361 raise
1362 except Exception:
-> 1363 _rebuild()
1364 else:
1365 _rebuild()
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\matplotlib\font_manager.py in _rebuild()
1342 global fontManager
1343
-> 1344 fontManager = FontManager()
1345
1346 if _fmcache:
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\matplotlib\font_manager.py in __init__(self, size, weight)
976 self.defaultFont = {}
977
--> 978 ttffiles = findSystemFonts(paths) + findSystemFonts()
979 self.defaultFont['ttf'] = next(
980 (fname for fname in ttffiles
C:\Users\cmoha\AppData\Local\Continuum\anaconda3\lib\site-packages\matplotlib\font_manager.py in findSystemFonts(fontpaths, fontext)
262 fontpaths = [win32FontDirectory()]
263 # now get all installed fonts directly...
--> 264 fontfiles.update(win32InstalledFonts(fontext=fontext))
265 else:
266 fontpaths = X11FontDirectories
TypeError: 'NoneType' object is not iterable