import pandas as pd
df = pd.read_csv('./csv/train.csv', header=0)
import pylab as P
df['Age'].hist()
P.show()
TclError Traceback (most recent call last) <ipython-input-2-25fb4a5af439> in <module>()
1 import pylab as P
----> 2 df['Age'].hist()
3 P.show()
/usr/lib/python2.7/dist-packages/pandas/tools/plotting.pyc in hist_series(self, by, ax, grid, xlabelsize, xrot, ylabelsize, yrot, figsize, **kwds) 2134 # hack until the plotting interface is a bit more unified 2135 fig = kwds.pop('figure', plt.gcf() if plt.get_fignums() else
-> 2136 plt.figure(figsize=figsize)) 2137 if (figsize is not None and tuple(figsize) != 2138 tuple(fig.get_size_inches())):
/usr/lib/pymodules/python2.7/matplotlib/pyplot.pyc in figure(num, figsize, dpi, facecolor, edgecolor, frameon, FigureClass, **kwargs)
421 frameon=frameon,
422 FigureClass=FigureClass,
--> 423 **kwargs)
424
425 if figLabel:
/usr/lib/pymodules/python2.7/matplotlib/backends/backend_tkagg.pyc in new_figure_manager(num, *args, **kwargs)
77 FigureClass = kwargs.pop('FigureClass', Figure)
78 figure = FigureClass(*args, **kwargs)
---> 79 return new_figure_manager_given_figure(num, figure)
80
81
/usr/lib/pymodules/python2.7/matplotlib/backends/backend_tkagg.pyc in new_figure_manager_given_figure(num, figure)
85 """
86 _focus = windowing.FocusManager()
---> 87 window = Tk.Tk()
88 window.withdraw()
89
/usr/lib/python2.7/lib-tk/Tkinter.py in __init__(self, screenName, baseName, className, useTk, sync, use) 1765 baseName = baseName + ext 1766 interactive = 0
-> 1767 self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use) 1768 if useTk: 1769 self._loadtk()
Asked
Active
Viewed 105 times
0

cchamberlain
- 17,444
- 7
- 59
- 72

AbstractSage
- 11
- 1
-
is that all the traceback? – Padraic Cunningham Feb 10 '15 at 18:38
-
Looks like something is borked in your installation as the error is bubbling up out of core-lib stuff. My guess is you have more than one version of tk installed. – tacaswell Feb 11 '15 at 04:54
-
@PadraicCunningham : yes that's all – AbstractSage Feb 11 '15 at 07:43
-
@tcaswell :Thanks but dpkg shows only one version installed . Installing the anaconda package finally solved my probelm – AbstractSage Feb 11 '15 at 07:45