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

Skip to content

Commit be46069

Browse files
committed
auto converting plot directive
1 parent 154cdc5 commit be46069

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

doc/users/annotations.rst

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,12 @@ consider: the location being annotated represented by the argument
1919
``xy`` and the location of the text ``xytext``. Both of these
2020
arguments are ``(x,y)`` tuples.
2121

22-
.. image:: gallery/pyplots/images/annotation_basic.py
23-
:include-source:
22+
.. figure:: ../gallery/pyplots/images/sphx_glr_annotation_basic_001.png
23+
:target: ../gallery/pyplots/annotation_basic.html
24+
:align: center
25+
:scale: 50
2426

27+
Annotation Basic
2528

2629
In this example, both the ``xy`` (arrow tip) and ``xytext`` locations
2730
(text location) are in data coordinates. There are a variety of other

examples/pylab_examples/ellipse_demo.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,7 @@
1313
ells = [Ellipse(xy=rnd.rand(2)*10, width=rnd.rand(), height=rnd.rand(), angle=rnd.rand()*360)
1414
for i in range(NUM)]
1515

16-
fig = plt.figure(0)
17-
ax = fig.add_subplot(111, aspect='equal')
16+
fig, ax = plt.subplots(subplot_kw={'aspect': 'equal'})
1817
for e in ells:
1918
ax.add_artist(e)
2019
e.set_clip_box(ax.bbox)

0 commit comments

Comments
 (0)