Skip to content

Commit 0750e66

Browse files
committed
axes_grid: examples directory reorganization
svn path=/trunk/matplotlib/; revision=7761
1 parent 4dd0afc commit 0750e66

14 files changed

+8
-52
lines changed

doc/mpl_toolkits/axes_grid/figures/demo_colorbar_with_inset_locator.py

Lines changed: 0 additions & 40 deletions
This file was deleted.

doc/mpl_toolkits/axes_grid/users/axes_divider.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,12 +81,12 @@ may consider it as [0:2, 1].
8181

8282
See the example,
8383

84-
.. plot:: mpl_toolkits/axes_grid/examples/simple_axes_divider2.py
84+
.. plot:: mpl_toolkits/axes_grid/figures/simple_axes_divider2.py
8585
:include-source:
8686

8787
You can adjust the size of the each axes accroding to their x or y
8888
data limits (AxesX and AxesY), similar to the axes aspect parameter.
8989

90-
.. plot:: mpl_toolkits/axes_grid/examples/simple_axes_divider3.py
90+
.. plot:: mpl_toolkits/axes_grid/figures/simple_axes_divider3.py
9191
:include-source:
9292

doc/mpl_toolkits/axes_grid/users/overview.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ yaxis of each axes are shared. ::
158158
origin="lower", interpolation="nearest")
159159

160160

161-
.. plot:: mpl_toolkits/axes_grid/examples/simple_rgb.py
161+
.. plot:: mpl_toolkits/axes_grid/figures/simple_rgb.py
162162

163163

164164

@@ -246,7 +246,7 @@ axes.
246246
Example 1. twinx
247247
----------------
248248

249-
.. plot:: mpl_toolkits/axes_grid/examples/parasite_simple.py
249+
.. plot:: mpl_toolkits/axes_grid/figures/parasite_simple.py
250250
:include-source:
251251

252252
Example 2. twin
@@ -290,13 +290,13 @@ For example, you can hide right, and top axis by ::
290290
ax.axis["top"].set_visible(False)
291291

292292

293-
.. plot:: mpl_toolkits/axes_grid/examples/simple_axisline3.py
293+
.. plot:: mpl_toolkits/axes_grid/figures/simple_axisline3.py
294294

295295

296296
SubplotZero gives you two more additional (floating?) axis of x=0 and
297297
y=0 (in data coordinate)
298298

299-
.. plot:: mpl_toolkits/axes_grid/examples/simple_axisline2.py
299+
.. plot:: mpl_toolkits/axes_grid/figures/simple_axisline2.py
300300
:include-source:
301301

302302

examples/axes_grid/demo_colorbar_with_inset_locator.py

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import matplotlib.pyplot as plt
22

33
from mpl_toolkits.axes_grid.inset_locator import inset_axes
4-
#from mpl_toolkits.axes_grid.colorbar import colorbar
4+
from mpl_toolkits.axes_grid.colorbar import colorbar
55

66
fig = plt.figure(1, [6, 3])
77

@@ -13,8 +13,6 @@
1313
height="5%", # height : 50%
1414
loc=1)
1515

16-
locator1=axins1.get_axes_locator()
17-
1816
im1=ax1.imshow([[1,2],[2, 3]])
1917
colorbar(im1, cax=axins1, orientation="horizontal", ticks=[1,2,3])
2018
axins1.xaxis.set_ticks_position("bottom")
@@ -31,14 +29,12 @@
3129
borderpad=0,
3230
)
3331

34-
35-
locator=axins.get_axes_locator()
3632
# Controlling the placement of the inset axes is basically same as that
3733
# of the legend. you may want to play with the borderpad value and
3834
# the bbox_to_anchor coordinate.
3935

4036
im=ax.imshow([[1,2],[2, 3]])
41-
colorbar(im, cax=axins)
37+
colorbar(im, cax=axins, ticks=[1,2,3])
4238

4339
plt.draw()
4440
plt.show()

0 commit comments

Comments
 (0)