@@ -506,7 +506,7 @@ def f(x):
506506 ax .plot (x , y , color = colors [kls ], label = label , ** kwds )
507507 else :
508508 ax .plot (x , y , color = colors [kls ], ** kwds )
509-
509+
510510 ax .legend (loc = 'upper right' )
511511 ax .grid ()
512512 return ax
@@ -754,7 +754,7 @@ class MPLPlot(object):
754754 """
755755 _default_rot = 0
756756
757- _pop_attributes = ['label' , 'style' , 'logy' , 'logx' , 'loglog' ,
757+ _pop_attributes = ['label' , 'style' , 'logy' , 'logx' , 'loglog' ,
758758 'mark_right' ]
759759 _attr_defaults = {'logy' : False , 'logx' : False , 'loglog' : False ,
760760 'mark_right' : True }
@@ -1002,8 +1002,8 @@ def _add_table(self):
10021002 data = self .data
10031003 data = data .transpose ()
10041004 else :
1005- data = self .table
1006- ax = self ._get_ax (0 )
1005+ data = self .table
1006+ ax = self ._get_ax (0 )
10071007 table (ax , data )
10081008
10091009 def _post_plot_logic (self ):
@@ -1545,7 +1545,7 @@ def _is_ts_plot(self):
15451545 def _make_plot (self ):
15461546 self ._pos_prior = np .zeros (len (self .data ))
15471547 self ._neg_prior = np .zeros (len (self .data ))
1548-
1548+
15491549 if self ._is_ts_plot ():
15501550 data = self ._maybe_convert_index (self .data )
15511551 self ._make_ts_plot (data )
@@ -1565,7 +1565,7 @@ def _make_plot(self):
15651565
15661566 errors = self ._get_errorbars (label = label , index = i )
15671567 kwds = dict (kwds , ** errors )
1568-
1568+
15691569 label = com .pprint_thing (label ) # .encode('utf-8')
15701570 kwds ['label' ] = label
15711571
@@ -1613,7 +1613,7 @@ def _get_stacked_values(self, y, label):
16131613 def _get_ts_plot_function (self ):
16141614 from pandas .tseries .plotting import tsplot
16151615 plotf = self ._get_plot_function ()
1616-
1616+
16171617 def _plot (data , ax , label , style , ** kwds ):
16181618 # errorbar function does not support style argument
16191619 if plotf .__name__ == 'errorbar' :
@@ -1722,7 +1722,7 @@ def _get_plot_function(self):
17221722 raise ValueError ("Log-y scales are not supported in area plot" )
17231723 else :
17241724 f = LinePlot ._get_plot_function (self )
1725-
1725+
17261726 def plotf (* args , ** kwds ):
17271727 lines = f (* args , ** kwds )
17281728
@@ -1746,12 +1746,12 @@ def plotf(*args, **kwds):
17461746
17471747 self .plt .Axes .fill_between (* args , ** kwds )
17481748 return lines
1749-
1749+
17501750 return plotf
17511751
17521752 def _add_legend_handle (self , handle , label , index = None ):
17531753 from matplotlib .patches import Rectangle
1754- # Because fill_between isn't supported in legend,
1754+ # Because fill_between isn't supported in legend,
17551755 # specifically add Rectangle handle here
17561756 alpha = self .kwds .get ('alpha' , 0.5 )
17571757 handle = Rectangle ((0 , 0 ), 1 , 1 , fc = handle .get_color (), alpha = alpha )
@@ -1766,14 +1766,14 @@ def _post_plot_logic(self):
17661766 if self .xlim is None :
17671767 for ax in self .axes :
17681768 ax .set_xlim (0 , len (self .data )- 1 )
1769-
1769+
17701770 if self .ylim is None :
17711771 if (self .data >= 0 ).all ().all ():
17721772 for ax in self .axes :
17731773 ax .set_ylim (0 , None )
17741774 elif (self .data <= 0 ).all ().all ():
17751775 for ax in self .axes :
1776- ax .set_ylim (None , 0 )
1776+ ax .set_ylim (None , 0 )
17771777
17781778
17791779class BarPlot (MPLPlot ):
@@ -1923,7 +1923,7 @@ def _args_adjust(self):
19231923 self .logy = False
19241924 self .logx = False
19251925 self .loglog = False
1926-
1926+
19271927 def _get_layout (self ):
19281928 from pandas import DataFrame
19291929 if isinstance (self .data , DataFrame ):
@@ -1982,8 +1982,8 @@ class HistPlot(MPLPlot):
19821982_series_kinds = ['pie' ]
19831983_all_kinds = _common_kinds + _dataframe_kinds + _series_kinds
19841984
1985- _plot_klass = {'line' : LinePlot , 'bar' : BarPlot , 'barh' : BarPlot ,
1986- 'kde' : KdePlot ,
1985+ _plot_klass = {'line' : LinePlot , 'bar' : BarPlot , 'barh' : BarPlot ,
1986+ 'kde' : KdePlot ,
19871987 'scatter' : ScatterPlot , 'hexbin' : HexBinPlot ,
19881988 'area' : AreaPlot , 'pie' : PiePlot }
19891989
@@ -2101,7 +2101,7 @@ def plot_frame(frame=None, x=None, y=None, subplots=False, sharex=True,
21012101 elif kind in _series_kinds :
21022102 if y is None and subplots is False :
21032103 msg = "{0} requires either y column or 'subplots=True'"
2104- raise ValueError (msg .format (kind ))
2104+ raise ValueError (msg .format (kind ))
21052105 elif y is not None :
21062106 if com .is_integer (y ) and not frame .columns .holds_integer ():
21072107 y = frame .columns [y ]
@@ -2113,8 +2113,8 @@ def plot_frame(frame=None, x=None, y=None, subplots=False, sharex=True,
21132113 fontsize = fontsize , use_index = use_index , sharex = sharex ,
21142114 sharey = sharey , xticks = xticks , yticks = yticks ,
21152115 xlim = xlim , ylim = ylim , title = title , grid = grid ,
2116- figsize = figsize ,
2117- sort_columns = sort_columns ,
2116+ figsize = figsize ,
2117+ sort_columns = sort_columns ,
21182118 ** kwds )
21192119 else :
21202120 if x is not None :
@@ -2504,7 +2504,7 @@ def hist_frame(data, column=None, by=None, grid=True, xlabelsize=None,
25042504 The size of the figure to create in inches by default
25052505 layout: (optional) a tuple (rows, columns) for the layout of the histograms
25062506 bins: integer, default 10
2507- Number of histogram bins to be used
2507+ Number of histogram bins to be used
25082508 kwds : other plotting keyword arguments
25092509 To be passed to hist function
25102510 """
@@ -2538,7 +2538,7 @@ def hist_frame(data, column=None, by=None, grid=True, xlabelsize=None,
25382538 sharex = sharex , sharey = sharey , figsize = figsize )
25392539
25402540 for i , col in enumerate (com ._try_sort (data .columns )):
2541- ax = axes [i / ncols , i % ncols ]
2541+ ax = axes [i // ncols , i % ncols ]
25422542 ax .xaxis .set_visible (True )
25432543 ax .yaxis .set_visible (True )
25442544 ax .hist (data [col ].dropna ().values , bins = bins , ** kwds )
@@ -2583,7 +2583,7 @@ def hist_series(self, by=None, ax=None, grid=True, xlabelsize=None,
25832583 figsize : tuple, default None
25842584 figure size in inches by default
25852585 bins: integer, default 10
2586- Number of histogram bins to be used
2586+ Number of histogram bins to be used
25872587 kwds : keywords
25882588 To be passed to the actual plotting function
25892589
@@ -3046,7 +3046,7 @@ def on_right(i):
30463046 if naxes != nplots :
30473047 for ax in axarr [naxes :]:
30483048 ax .set_visible (False )
3049-
3049+
30503050 if squeeze :
30513051 # Reshape the array to have the final desired dimension (nrow,ncol),
30523052 # though discarding unneeded dimensions that equal 1. If we only have
0 commit comments