Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 987893c

Browse files
committed
MNT: got rid of build-breaking u'' strings in pyplot
1 parent ffdbd7d commit 987893c

1 file changed

Lines changed: 18 additions & 19 deletions

File tree

lib/matplotlib/pyplot.py

Lines changed: 18 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,6 @@ def switch_backend(newbackend):
132132
def show(*args, **kw):
133133
"""
134134
Display a figure.
135-
136135
When running in ipython with its pylab mode, display all
137136
figures and return to the ipython prompt.
138137
@@ -2588,7 +2587,7 @@ def broken_barh(xranges, yrange, hold=None, **kwargs):
25882587
# This function was autogenerated by boilerplate.py. Do not edit as
25892588
# changes will be lost
25902589
@_autogen_docstring(Axes.boxplot)
2591-
def boxplot(x, notch=False, sym=u'b+', vert=True, whis=1.5, positions=None,
2590+
def boxplot(x, notch=False, sym='b+', vert=True, whis=1.5, positions=None,
25922591
widths=None, patch_artist=False, bootstrap=None, usermedians=None,
25932592
conf_intervals=None, hold=None):
25942593
ax = gca()
@@ -2613,7 +2612,7 @@ def boxplot(x, notch=False, sym=u'b+', vert=True, whis=1.5, positions=None,
26132612
@_autogen_docstring(Axes.cohere)
26142613
def cohere(x, y, NFFT=256, Fs=2, Fc=0, detrend=mlab.detrend_none,
26152614
window=mlab.window_hanning, noverlap=0, pad_to=None,
2616-
sides=u'default', scale_by_freq=None, hold=None, **kwargs):
2615+
sides='default', scale_by_freq=None, hold=None, **kwargs):
26172616
ax = gca()
26182617
# allow callers to override the hold state by passing hold=True|False
26192618
washold = ax.ishold()
@@ -2710,7 +2709,7 @@ def csd(x, y, NFFT=None, Fs=None, Fc=None, detrend=None, window=None,
27102709
# This function was autogenerated by boilerplate.py. Do not edit as
27112710
# changes will be lost
27122711
@_autogen_docstring(Axes.errorbar)
2713-
def errorbar(x, y, yerr=None, xerr=None, fmt=u'-', ecolor=None, elinewidth=None,
2712+
def errorbar(x, y, yerr=None, xerr=None, fmt='-', ecolor=None, elinewidth=None,
27142713
capsize=3, barsabove=False, lolims=False, uplims=False,
27152714
xlolims=False, xuplims=False, errorevery=1, capthick=None,
27162715
hold=None, **kwargs):
@@ -2735,8 +2734,8 @@ def errorbar(x, y, yerr=None, xerr=None, fmt=u'-', ecolor=None, elinewidth=None,
27352734
# This function was autogenerated by boilerplate.py. Do not edit as
27362735
# changes will be lost
27372736
@_autogen_docstring(Axes.eventplot)
2738-
def eventplot(positions, orientation=u'horizontal', lineoffsets=1,
2739-
linelengths=1, linewidths=None, colors=None, linestyles=u'solid',
2737+
def eventplot(positions, orientation='horizontal', lineoffsets=1,
2738+
linelengths=1, linewidths=None, colors=None, linestyles='solid',
27402739
hold=None, **kwargs):
27412740
ax = gca()
27422741
# allow callers to override the hold state by passing hold=True|False
@@ -2813,9 +2812,9 @@ def fill_betweenx(y, x1, x2=0, where=None, hold=None, **kwargs):
28132812
# This function was autogenerated by boilerplate.py. Do not edit as
28142813
# changes will be lost
28152814
@_autogen_docstring(Axes.hexbin)
2816-
def hexbin(x, y, C=None, gridsize=100, bins=None, xscale=u'linear',
2817-
yscale=u'linear', extent=None, cmap=None, norm=None, vmin=None,
2818-
vmax=None, alpha=None, linewidths=None, edgecolors=u'none',
2815+
def hexbin(x, y, C=None, gridsize=100, bins=None, xscale='linear',
2816+
yscale='linear', extent=None, cmap=None, norm=None, vmin=None,
2817+
vmax=None, alpha=None, linewidths=None, edgecolors='none',
28192818
reduce_C_function=np.mean, mincnt=None, marginals=False, hold=None,
28202819
**kwargs):
28212820
ax = gca()
@@ -2841,7 +2840,7 @@ def hexbin(x, y, C=None, gridsize=100, bins=None, xscale=u'linear',
28412840
# changes will be lost
28422841
@_autogen_docstring(Axes.hist)
28432842
def hist(x, bins=10, range=None, normed=False, weights=None, cumulative=False,
2844-
bottom=None, histtype=u'bar', align=u'mid', orientation=u'vertical',
2843+
bottom=None, histtype='bar', align='mid', orientation='vertical',
28452844
rwidth=None, log=False, color=None, label=None, stacked=False,
28462845
hold=None, **kwargs):
28472846
ax = gca()
@@ -2885,7 +2884,7 @@ def hist2d(x, y, bins=10, range=None, normed=False, weights=None, cmin=None,
28852884
# This function was autogenerated by boilerplate.py. Do not edit as
28862885
# changes will be lost
28872886
@_autogen_docstring(Axes.hlines)
2888-
def hlines(y, xmin, xmax, colors=u'k', linestyles=u'solid', label=u'',
2887+
def hlines(y, xmin, xmax, colors='k', linestyles='solid', label='',
28892888
hold=None, **kwargs):
28902889
ax = gca()
28912890
# allow callers to override the hold state by passing hold=True|False
@@ -3066,7 +3065,7 @@ def plot(*args, **kwargs):
30663065
# This function was autogenerated by boilerplate.py. Do not edit as
30673066
# changes will be lost
30683067
@_autogen_docstring(Axes.plot_date)
3069-
def plot_date(x, y, fmt=u'bo', tz=None, xdate=True, ydate=False, hold=None,
3068+
def plot_date(x, y, fmt='bo', tz=None, xdate=True, ydate=False, hold=None,
30703069
**kwargs):
30713070
ax = gca()
30723071
# allow callers to override the hold state by passing hold=True|False
@@ -3145,7 +3144,7 @@ def quiverkey(*args, **kw):
31453144
# This function was autogenerated by boilerplate.py. Do not edit as
31463145
# changes will be lost
31473146
@_autogen_docstring(Axes.scatter)
3148-
def scatter(x, y, s=20, c=u'b', marker=u'o', cmap=None, norm=None, vmin=None,
3147+
def scatter(x, y, s=20, c='b', marker='o', cmap=None, norm=None, vmin=None,
31493148
vmax=None, alpha=None, linewidths=None, verts=None, hold=None,
31503149
**kwargs):
31513150
ax = gca()
@@ -3283,7 +3282,7 @@ def step(x, y, *args, **kwargs):
32833282
# changes will be lost
32843283
@_autogen_docstring(Axes.streamplot)
32853284
def streamplot(x, y, u, v, density=1, linewidth=None, color=None, cmap=None,
3286-
norm=None, arrowsize=1, arrowstyle=u'-|>', minlength=0.1,
3285+
norm=None, arrowsize=1, arrowstyle='-|>', minlength=0.1,
32873286
transform=None, zorder=1, hold=None):
32883287
ax = gca()
32893288
# allow callers to override the hold state by passing hold=True|False
@@ -3378,7 +3377,7 @@ def triplot(*args, **kwargs):
33783377
# This function was autogenerated by boilerplate.py. Do not edit as
33793378
# changes will be lost
33803379
@_autogen_docstring(Axes.vlines)
3381-
def vlines(x, ymin, ymax, colors=u'k', linestyles=u'solid', label=u'',
3380+
def vlines(x, ymin, ymax, colors='k', linestyles='solid', label='',
33823381
hold=None, **kwargs):
33833382
ax = gca()
33843383
# allow callers to override the hold state by passing hold=True|False
@@ -3444,7 +3443,7 @@ def cla():
34443443
# This function was autogenerated by boilerplate.py. Do not edit as
34453444
# changes will be lost
34463445
@docstring.copy_dedent(Axes.grid)
3447-
def grid(b=None, which=u'major', axis=u'both', **kwargs):
3446+
def grid(b=None, which='major', axis='both', **kwargs):
34483447
ret = gca().grid(b=b, which=which, axis=axis, **kwargs)
34493448
draw_if_interactive()
34503449
return ret
@@ -3492,15 +3491,15 @@ def ticklabel_format(**kwargs):
34923491
# This function was autogenerated by boilerplate.py. Do not edit as
34933492
# changes will be lost
34943493
@docstring.copy_dedent(Axes.locator_params)
3495-
def locator_params(axis=u'both', tight=None, **kwargs):
3494+
def locator_params(axis='both', tight=None, **kwargs):
34963495
ret = gca().locator_params(axis=axis, tight=tight, **kwargs)
34973496
draw_if_interactive()
34983497
return ret
34993498

35003499
# This function was autogenerated by boilerplate.py. Do not edit as
35013500
# changes will be lost
35023501
@docstring.copy_dedent(Axes.tick_params)
3503-
def tick_params(axis=u'both', **kwargs):
3502+
def tick_params(axis='both', **kwargs):
35043503
ret = gca().tick_params(axis=axis, **kwargs)
35053504
draw_if_interactive()
35063505
return ret
@@ -3516,7 +3515,7 @@ def margins(*args, **kw):
35163515
# This function was autogenerated by boilerplate.py. Do not edit as
35173516
# changes will be lost
35183517
@docstring.copy_dedent(Axes.autoscale)
3519-
def autoscale(enable=True, axis=u'both', tight=None):
3518+
def autoscale(enable=True, axis='both', tight=None):
35203519
ret = gca().autoscale(enable=enable, axis=axis, tight=tight)
35213520
draw_if_interactive()
35223521
return ret

0 commit comments

Comments
 (0)