From df9e3fdbac2ea60cf5e8aa2856517ee5228b1e33 Mon Sep 17 00:00:00 2001 From: Thomas A Caswell Date: Mon, 26 Aug 2019 22:57:04 -0400 Subject: [PATCH 1/3] DOC: add correct file extension --- doc/api/next_api_changes/{2019-08-08-TH => 2019-08-08-TH.rst} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename doc/api/next_api_changes/{2019-08-08-TH => 2019-08-08-TH.rst} (100%) diff --git a/doc/api/next_api_changes/2019-08-08-TH b/doc/api/next_api_changes/2019-08-08-TH.rst similarity index 100% rename from doc/api/next_api_changes/2019-08-08-TH rename to doc/api/next_api_changes/2019-08-08-TH.rst From 66b98b29c220000ff9eb5b2bf4ef544bffcbe76b Mon Sep 17 00:00:00 2001 From: Thomas A Caswell Date: Mon, 26 Aug 2019 23:22:56 -0400 Subject: [PATCH 2/3] DOC: add example --- doc/api/next_api_changes/2019-07-18-SL.rst | 24 +++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/doc/api/next_api_changes/2019-07-18-SL.rst b/doc/api/next_api_changes/2019-07-18-SL.rst index f9038e290475..94d061bce6df 100644 --- a/doc/api/next_api_changes/2019-07-18-SL.rst +++ b/doc/api/next_api_changes/2019-07-18-SL.rst @@ -1,4 +1,26 @@ Reduced default value of :rc:`axes.formatter.limits` ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -Changed the default value of :rc:`axes.formatter.limits` from -7, 7 to -5, 6 for better readability. +Changed the default value of :rc:`axes.formatter.limits` from -7, 7 to +-5, 6 for better readability. + +.. plot:: + + import matplotlib.pyplot as plt + import numpy as np + + fig, [ax_old, ax_new] = plt.subplots(1, 2, constrained_layout=True) + + ax_new.set_title('new values (-5, 6)') + ax_old.set_title('old values (-7, 7)') + + x = np.logspace(-8, 8, 1024) + y = 1e-5 * np.exp(-x / 1e5) + 1e-6 + + ax_old.xaxis.get_major_formatter().set_powerlimits((-7, 7)) + ax_old.yaxis.get_major_formatter().set_powerlimits((-7, 7)) + + for ax in [ax_new, ax_old]: + ax.plot(x, y) + ax.set_xlim(0, 1e6) + ax.set_ylim(1e-6, 1e-5) From cb2b8143c909b04975ce1398bb36aa47fa8f9be3 Mon Sep 17 00:00:00 2001 From: Thomas A Caswell Date: Tue, 27 Aug 2019 11:22:52 -0400 Subject: [PATCH 3/3] STY: tuple vs list Co-Authored-By: Tim Hoffmann <2836374+timhoffm@users.noreply.github.com> --- doc/api/next_api_changes/2019-07-18-SL.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/api/next_api_changes/2019-07-18-SL.rst b/doc/api/next_api_changes/2019-07-18-SL.rst index 94d061bce6df..659e63b47033 100644 --- a/doc/api/next_api_changes/2019-07-18-SL.rst +++ b/doc/api/next_api_changes/2019-07-18-SL.rst @@ -9,7 +9,7 @@ Changed the default value of :rc:`axes.formatter.limits` from -7, 7 to import matplotlib.pyplot as plt import numpy as np - fig, [ax_old, ax_new] = plt.subplots(1, 2, constrained_layout=True) + fig, (ax_old, ax_new) = plt.subplots(1, 2, constrained_layout=True) ax_new.set_title('new values (-5, 6)') ax_old.set_title('old values (-7, 7)')