diff --git a/doc/users/whats_new/2014-12-23_usetex.rst b/doc/users/whats_new/2014-12-23_usetex.rst index 5a676b13a7ce..ebc71e88670a 100644 --- a/doc/users/whats_new/2014-12-23_usetex.rst +++ b/doc/users/whats_new/2014-12-23_usetex.rst @@ -1,5 +1,5 @@ Artist-level {get,set}_usetex for text -------------------------------------- -Add `{get,set}_usetex` methods to `text.Text` objects which allow artist-level +Add ``{get,set}_usetex`` methods to `text.Text` objects which allow artist-level control of LaTeX rendering vs the internal mathtex rendering. diff --git a/doc/users/whats_new/2015-03-03_locator-set_params.rst b/doc/users/whats_new/2015-03-03_locator-set_params.rst index 22b95b7315ed..baf53e527959 100755 --- a/doc/users/whats_new/2015-03-03_locator-set_params.rst +++ b/doc/users/whats_new/2015-03-03_locator-set_params.rst @@ -5,7 +5,7 @@ set_params() function, which sets parameters within a Locator type instance, is now available to all Locator types. The implementation also prevents unsafe usage by strictly defining the parameters that a user can set. -To use, simply call set_params() on a Locator instance with desired arguments: +To use, simply call ``set_params()`` on a Locator instance with desired arguments: :: loc = matplotlib.ticker.LogLocator() diff --git a/doc/users/whats_new/autowrap_text.rst b/doc/users/whats_new/autowrap_text.rst index bdd8a9024097..649fb4e0fb7b 100644 --- a/doc/users/whats_new/autowrap_text.rst +++ b/doc/users/whats_new/autowrap_text.rst @@ -3,5 +3,8 @@ Auto-wrapping Text Added the keyword argument "wrap" to Text, which automatically breaks long lines of text when being drawn. Works for any rotated text, different modes of alignment, and for text that are either labels or titles. -Example: - plt.text(1, 1, "This is a really long string that should be wrapped so that it does not go outside the figure.", wrap=True) \ No newline at end of file +Example :: + + plt.text(1, 1, + "This is a really long string that should be wrapped so that " + "it does not go outside the figure.", wrap=True) diff --git a/doc/users/whats_new/axis3d.rst b/doc/users/whats_new/axis3d.rst index 23dd21d55c39..6a6df37494bc 100644 --- a/doc/users/whats_new/axis3d.rst +++ b/doc/users/whats_new/axis3d.rst @@ -1,6 +1,6 @@ Fixed labelpad in Axis3D -``````````````````````````````````` +```````````````````````` Axis3D now looks at xaxis.labelpad (from rcParams or set by -set_xlabel('X LABEL', labelpad=30) or ax.zaxis.labelpad = 20) -to determine the position of axis labels in 3D plots. +``set_xlabel('X LABEL', labelpad=30)`` or ``ax.zaxis.labelpad=20)`` to +determine the position of axis labels in 3D plots. diff --git a/doc/users/whats_new/cbook.rst b/doc/users/whats_new/cbook.rst index c5296b7cbbc0..e4e98139e436 100644 --- a/doc/users/whats_new/cbook.rst +++ b/doc/users/whats_new/cbook.rst @@ -1,7 +1,7 @@ cbook.is_sequence_of_strings recognizes string objects `````````````````````````````````````````````````````` -This is primarily how pandas stores a sequence of strings. +This is primarily how pandas stores a sequence of strings :: import pandas as pd import matplotlib.cbook as cbook diff --git a/doc/users/whats_new/datelocators.rst b/doc/users/whats_new/datelocators.rst index b894a323587d..bd143894f389 100644 --- a/doc/users/whats_new/datelocators.rst +++ b/doc/users/whats_new/datelocators.rst @@ -5,7 +5,7 @@ Date Locators (derived from :class:`~matplotlib.dates.DateLocator`) now implement the :meth:`~matplotlib.tickers.Locator.tick_values` method. This is expected of all Locators derived from :class:`~matplotlib.tickers.Locator`. -The Date Locators can now be used easily without creating axes +The Date Locators can now be used easily without creating axes :: from datetime import datetime from matplotlib.dates import YearLocator diff --git a/doc/users/whats_new/linestyles.rst b/doc/users/whats_new/linestyles.rst index 53a273a7dfd0..e62f6b45d779 100644 --- a/doc/users/whats_new/linestyles.rst +++ b/doc/users/whats_new/linestyles.rst @@ -1,8 +1,8 @@ -Mostly unified linestyles for Lines, Patches and Collections -```````````````````````````````````````````````````````````` +Mostly unified linestyles for `Line2D`, `Patche` and `Collection` +````````````````````````````````````````````````````````````````` The handling of linestyles for Lines, Patches and Collections has been unified. Now they all support defining linestyles with short symbols, -like `"--"`, as well as with full names, like `"dashed"`. Also the -definition using a dash pattern (`(0., [3., 3.])`) is supported for all -methods using Lines, Patches or Collections. +like `"--"`, as well as with full names, like ``"dashed"``. Also the +definition using a dash pattern (``(0., [3., 3.])``) is supported for all +methods using `Line2D`, `Patche` or ``Collection*``. diff --git a/doc/users/whats_new/pdfpages_notes.rst b/doc/users/whats_new/pdfpages_notes.rst index 9f4784ff76e8..ba4ecab7d660 100644 --- a/doc/users/whats_new/pdfpages_notes.rst +++ b/doc/users/whats_new/pdfpages_notes.rst @@ -8,5 +8,5 @@ viewer that has this facility (Adobe Reader, OSX Preview, Skim, etc.). Per default the note itself is kept off-page to prevent it to appear in print-outs. -PdfPages.attach_note needs to be called before savefig in order to be +`PdfPages.attach_note` needs to be called before savefig in order to be added to the correct figure. diff --git a/doc/users/whats_new/plotting.rst b/doc/users/whats_new/plotting.rst index 1ca2f6a69434..80a4711111ec 100644 --- a/doc/users/whats_new/plotting.rst +++ b/doc/users/whats_new/plotting.rst @@ -1,10 +1,12 @@ Plot bar and barh with labels ````````````````````````````` -Added kwarg "tick_label" to bar and barh to support plotting bar graphs with a +Added kwarg ``"tick_label"`` to `bar` and `barh` to support plotting bar graphs with a text label for each bar. -Example: - bar([1, 2], [1, 1], tick_label=['bar1', 'bar2']) + +Example: :: + + bar([1, 2], [1, 1], tick_label=['bar1', 'bar2']) Added center and frame kwargs to pie ```````````````````````````````````` diff --git a/doc/users/whats_new/updated_backend_wx.rst b/doc/users/whats_new/updated_backend_wx.rst index 00e324ecc59e..cbfb7995f241 100644 --- a/doc/users/whats_new/updated_backend_wx.rst +++ b/doc/users/whats_new/updated_backend_wx.rst @@ -1,13 +1,14 @@ wx backend has been updated --------------------------- + The wx backend can now be used with both wxPython classic and `Phoenix `__. wxPython classic has to be at least version 2.8.12 and works on Python 2.x. As -of May 2015 no official release of wxPython Phoenix is available but a +of May 2015 no official release of wxPython Phoenix is available but a current snapshot will work on Python 2.7+ and 3.4+. If you have multiple versions of wxPython installed, then the user code is responsible setting the wxPython version. How to do this is -explained in the comment at the beginning of the example +explained in the comment at the beginning of the example `examples\user_interfaces\embedding_in_wx2.py`. diff --git a/doc/users/whats_new/updated_figimage.rst b/doc/users/whats_new/updated_figimage.rst index d9198e225503..22fd6e79d9cf 100644 --- a/doc/users/whats_new/updated_figimage.rst +++ b/doc/users/whats_new/updated_figimage.rst @@ -1,8 +1,10 @@ updated figimage to take optional resize parameter ---------------------------------------------------- -Added the ability to plot simple 2D-Array using plt.figimage(X, resize=True). + +Added the ability to plot simple 2D-Array using ``plt.figimage(X, resize=True)``. This is useful for plotting simple 2D-Array without the Axes or whitespacing around the image. -Example: - data = np.random.random( [500, 500] ) - plt.figimage(data, resize=True) +Example:: + + data = np.random.random( [500, 500] ) + plt.figimage(data, resize=True) diff --git a/doc/users/whats_new/updated_figure.rst b/doc/users/whats_new/updated_figure.rst index 881fb1192dc4..16cb8686125c 100644 --- a/doc/users/whats_new/updated_figure.rst +++ b/doc/users/whats_new/updated_figure.rst @@ -3,7 +3,8 @@ Updated Figure.savefig() Added support to save the figure with the same dpi as the figure on the screen using dpi='figure' -Example: - f = plt.figure(dpi=25) # dpi set to 25 - S = plt.scatter([1,2,3],[4,5,6]) - f.savefig('output.png', dpi='figure') # output savefig dpi set to 25 (same as figure) +Example:: + + f = plt.figure(dpi=25) # dpi set to 25 + S = plt.scatter([1,2,3],[4,5,6]) + f.savefig('output.png', dpi='figure') # output savefig dpi set to 25 (same as figure) diff --git a/doc/users/whats_new/updated_pyplot.rst b/doc/users/whats_new/updated_pyplot.rst index 7e525c9f761a..daff292ef1e2 100644 --- a/doc/users/whats_new/updated_pyplot.rst +++ b/doc/users/whats_new/updated_pyplot.rst @@ -1,7 +1,9 @@ -Updated fignum_exists to take figure name +Updated fignum_exists to take figure name ------------------------------------------- + Added the ability to check the existence of a figure using it's name instead of just the figure number. -Example: - figure('figure') - fignum_exists('figure') #true \ No newline at end of file +Example:: + + figure('figure') + fignum_exists('figure') #true diff --git a/doc/users/whats_new/updated_scale.rst b/doc/users/whats_new/updated_scale.rst index df1a5bc2be80..b8d86c4c9ad2 100644 --- a/doc/users/whats_new/updated_scale.rst +++ b/doc/users/whats_new/updated_scale.rst @@ -1,4 +1,10 @@ Logit Scale ----------- + Added support for the 'logit' axis scale, a nonlinear transformation -`x -> log10(x / (1-x))` for data between 0 and 1 excluded. + +.. math:: + + x -> \log10(x / (1-x)) + +for data between 0 and 1 excluded. diff --git a/doc/users/whats_new/updated_table.rst b/doc/users/whats_new/updated_table.rst index f00b00a8fbb2..bed0d5cd88d4 100644 --- a/doc/users/whats_new/updated_table.rst +++ b/doc/users/whats_new/updated_table.rst @@ -1,10 +1,14 @@ Updated Table and to control edge visibility -------------------------------------------- + Added the ability to toggle the visibility of lines in Tables. -Functionality added to the table() factory function under the keyword argument "edges". -Values can be the strings "open", "closed", "horizontal", "vertical" or combinations of the letters "L", "R", "T", "B" which represent left, right, top, and bottom respectively. +Functionality added to the table() factory function under the keyword +argument "edges". Values can be the strings "open", "closed", +"horizontal", "vertical" or combinations of the letters "L", "R", "T", +"B" which represent left, right, top, and bottom respectively. + +Example:: -Example: table(..., edges="open") # No line visible table(..., edges="closed") # All lines visible table(..., edges="horizontal") # Only top and bottom lines visible diff --git a/doc/users/whats_new/updated_widgets.rst b/doc/users/whats_new/updated_widgets.rst index 702be6f0cefb..0ec3263d1574 100644 --- a/doc/users/whats_new/updated_widgets.rst +++ b/doc/users/whats_new/updated_widgets.rst @@ -1,10 +1,13 @@ Moved ``ignore``, ``set_active``, and ``get_active`` methods to base class ``Widget`` -````````````````````````````````````````````````````````````````````````````````` +````````````````````````````````````````````````````````````````````````````````````` + Pushes up duplicate methods in child class to parent class to avoid duplication of code. Adds enable/disable feature to MultiCursor `````````````````````````````````````````` -A MultiCursor object can be disabled (and enabled) after it has been created without destroying the object. -Example: - multi_cursor.active = False + +A MultiCursor object can be disabled (and enabled) after it has been created without destroying the object. +Example:: + + multi_cursor.active = False