Skip to content

Commit 729422c

Browse files
committed
added whats new for 1.0
svn path=/trunk/matplotlib/; revision=8498
1 parent 6596c4a commit 729422c

File tree

3 files changed

+173
-1
lines changed

3 files changed

+173
-1
lines changed

doc/api/gridspec_api.rst

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
*************
2+
matplotlib gridspec
3+
*************
4+
5+
6+
:mod:`matplotlib.gridspec`
7+
====================
8+
9+
.. automodule:: matplotlib.gridspec
10+
:members:
11+
:undoc-members:
12+
:show-inheritance:

doc/pyplots/whats_new_1_subplot3d.py

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
from mpl_toolkits.mplot3d.axes3d import Axes3D
2+
from matplotlib import cm
3+
#from matplotlib.ticker import LinearLocator, FixedLocator, FormatStrFormatter
4+
import matplotlib.pyplot as plt
5+
import numpy as np
6+
7+
fig = plt.figure()
8+
9+
ax = fig.add_subplot(1, 2, 1, projection='3d')
10+
X = np.arange(-5, 5, 0.25)
11+
Y = np.arange(-5, 5, 0.25)
12+
X, Y = np.meshgrid(X, Y)
13+
R = np.sqrt(X**2 + Y**2)
14+
Z = np.sin(R)
15+
surf = ax.plot_surface(X, Y, Z, rstride=1, cstride=1, cmap=cm.jet,
16+
linewidth=0, antialiased=False)
17+
ax.set_zlim3d(-1.01, 1.01)
18+
19+
#ax.w_zaxis.set_major_locator(LinearLocator(10))
20+
#ax.w_zaxis.set_major_formatter(FormatStrFormatter('%.03f'))
21+
22+
fig.colorbar(surf, shrink=0.5, aspect=5)
23+
24+
from mpl_toolkits.mplot3d.axes3d import get_test_data
25+
ax = fig.add_subplot(1, 2, 2, projection='3d')
26+
X, Y, Z = get_test_data(0.05)
27+
ax.plot_wireframe(X, Y, Z, rstride=10, cstride=10)
28+
29+
plt.show()
30+

doc/users/whats_new.rst

Lines changed: 131 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,139 @@ What's new in matplotlib
77
This page just covers the highlights -- for the full story, see the
88
`CHANGELOG <http://matplotlib.sourceforge.net/_static/CHANGELOG>`_
99

10+
new in matplotlib-1.0
11+
======================
12+
13+
.. _whats-new-html5:
14+
15+
HTML5/Canvas backend
16+
---------------------
17+
18+
Simon Ratcliffe and Ludwig Schwardt have released an `HTML5/Canvas
19+
<http://code.google.com/p/mplh5canvas/>`_ backend for matplotlib. The
20+
backend is almost feature complete, and they have done a lot of work
21+
comparing their html5 rendered images with our core renderer Agg. The
22+
backend features client/server interactive navigation of matplotlib
23+
figures in an html5 compliant browser.
24+
25+
Sophisticated subplot grid layout
26+
---------------------------------
27+
28+
Jae-Joon Lee has written :mod:`~matplotlib.gridspec`, a new module for
29+
doing complex subplot layouts, featuring row and column spans and
30+
more. See :ref:`gridspec` for a tutorial overview.
31+
32+
.. plot:: users/plotting/examples/demo_gridspec01.py
33+
34+
Easy pythonic subplots
35+
-----------------------
36+
37+
Fernando Perez got tired of all the boilerplate code needed to create a
38+
figure and multiple subplots when using the matplotlib API, and wrote
39+
a :func:`~matplotlib.pyplot.subplots` helper function. Basic usage
40+
allows you to create the figure and an array of subplots with numpy
41+
indexing (starts with 0). Eg::
42+
43+
fig, axarr = plt.subplots(2, 2)
44+
axarr[0,0].plot([1,2,3]) # upper, left
45+
46+
See :ref:`pylab_examples-subplots_demo` for several code examples.
47+
48+
Contour fixes and and triplot
49+
---------------------------------
50+
51+
Ian Thomas has fixed a long-standing bug that has vexed our most
52+
talented developers for years. :func:`~matplotlib.pyplot.contourf`
53+
now handles interior masked regions, and the boundaries of line and
54+
filled contours coincide.
55+
56+
Additionally, he has contributed a new module `matplotlib.tri` and
57+
helper function :func:`~matplotlib.pyplot.triplot` for creating and
58+
plotting unstructured triangular grids.
59+
60+
.. plot:: mpl_examples/pylab_examples/triplot_demo.py
61+
62+
multiple calls to show supported
63+
---------------------------------
64+
65+
A long standing request is to support multiple calls to
66+
:func:`~matplotlib.pyplot.show`. This has been difficult because it
67+
is hard to get consistent behavior across operating systems, user
68+
interface toolkits and versions. Eric Firing has done a lot of work
69+
on rationalizing show across backends, with the desired behavior to
70+
make show raise all newly created figures and block execution until
71+
they are closed. Repeated calls to show should raise newly created
72+
figures since the last call. Eric has done a lot of testing on the
73+
user interface toolkits and versions and platforms he has access to,
74+
but it is not possible to test them all, so please report problems to
75+
the `mailing list
76+
<http://sourceforge.net/mailarchive/forum.php?forum_name=matplotlib-users>`_
77+
and `bug tracker
78+
<http://sourceforge.net/tracker/?group_id=80706&atid=560720>`_.
79+
80+
81+
mplot3d graphs can be embedded in arbitrary axes
82+
-------------------------------------------------
83+
84+
You can now place an mplot3d graph into an arbitrary axes location,
85+
supporting mixing of 2D and 3D graphs in the same figure, and/or
86+
multiple 3D graphs in a single figure, using the "projection" keyword
87+
argument to add_axes or add_subplot. Thanks Ben Root.
88+
89+
.. plot:: pyplots/whats_new_1_subplot3d.py
90+
91+
tick_params
92+
------------
93+
94+
Eric Firing wrote tick_params, a convenience method for changing the
95+
appearance of ticks and tick labels. See pyplot function
96+
:func:`~matplotlib.pyplot.tick_params` and associated Axes method
97+
:meth:`~matplotlib.axes.Axes.tick_params`.
98+
99+
Lots of performance and feature enhancements
100+
---------------------------------------------
101+
102+
103+
* Faster magnification of large images, and the ability to zoom in to
104+
a single pixel
105+
106+
* Local installs of documentation work better
107+
108+
* Improved "widgets" -- mouse grabbing is supported
109+
110+
* More accurate snapping of lines to pixel boundaries
111+
112+
* More consistent handling of color, particularly the alpha channel,
113+
throughout the API
114+
115+
Much improved software carpentry
116+
---------------------------------
117+
118+
The matplotlib trunk is probably in as good a shape as it has ever
119+
been, thanks to improved software carpentry. We now have a buildbot
120+
which runs a suite of nose regression tests on every svn commit,
121+
auto-generating a set of images and comparing them against a set of
122+
known-goods, sending emails to developers on failures with a
123+
pixel-by-pixel image comparison. Releases and release bugfixes happen
124+
in branches, allowing active new feature development to happen in the
125+
trunk while keeping the release branches stable. Thanks to Andrew
126+
Straw, Michael Droettboom and other matplotlib developers for the
127+
heavy lifting.
128+
129+
Bugfix marathon
130+
----------------
131+
132+
Eric Firing went on a bug fixing and closing marathon, closing over
133+
100 bugs on the `bug tracker
134+
<http://sourceforge.net/tracker/?group_id=80706&atid=560720>`_ with
135+
help from Jae-Joon Lee, Michael Droettboom, Christoph Gohlke and
136+
Michiel de Hoon.
137+
138+
10139
new in matplotlib-0.99
11140
======================
12141

13-
.. _whats-new-mplot3d:
142+
14143

15144
New documentation
16145
-----------------
@@ -21,6 +150,7 @@ and :ref:`plotting-guide-annotation`. Michael Sarahan has written
21150
working with paths and transformations: :ref:`path_tutorial` and
22151
:ref:`transforms_tutorial`.
23152

153+
.. _whats-new-mplot3d:
24154

25155
mplot3d
26156
--------

0 commit comments

Comments
 (0)