Revision: 8754 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8754&view=rev Author: jdh2358 Date: 2010-10-15 13:34:49 +0000 (Fri, 15 Oct 2010)
Log Message: ----------- added chipy talk video and some notes about transforms Modified Paths: -------------- branches/v1_0_maint/doc/_templates/indexsidebar.html branches/v1_0_maint/doc/users/transforms_tutorial.rst Modified: branches/v1_0_maint/doc/_templates/indexsidebar.html =================================================================== --- branches/v1_0_maint/doc/_templates/indexsidebar.html 2010-10-13 18:04:01 UTC (rev 8753) +++ branches/v1_0_maint/doc/_templates/indexsidebar.html 2010-10-15 13:34:49 UTC (rev 8754) @@ -27,7 +27,12 @@ <p>Watch the <a href="http://conference.scipy.org/">SciPy</a> 2009 <a href="http://www.archive.org/details/scipy09_introTutorialDay2_1">intro</a> and <a href="http://www.archive.org/details/scipy09_advancedTutorialDay1_3">advanced</a> matplotlib tutorials </p> -<p>Watch a <a href="http://videolectures.net/mloss08_hunter_mat">talk</a> about matplotlib presented at <a href="http://videolectures.net/mloss08_whistler">NIPS 08 Workshop</a> <i>MLOSS</i></a>. +<p>Watch +a <a href="http://videolectures.net/mloss08_hunter_mat">talk</a> about +matplotlib presented +at <a href="http://videolectures.net/mloss08_whistler">NIPS 08 +Workshop</a> <i>MLOSS</i></a> and one <a href="http://carlfk.blip.tv/file/2557425">presented</a> +at <a href="http://chipy.org">ChiPy</a>. </p> Modified: branches/v1_0_maint/doc/users/transforms_tutorial.rst =================================================================== --- branches/v1_0_maint/doc/users/transforms_tutorial.rst 2010-10-13 18:04:01 UTC (rev 8753) +++ branches/v1_0_maint/doc/users/transforms_tutorial.rst 2010-10-15 13:34:49 UTC (rev 8754) @@ -261,15 +261,27 @@ plt.show() +.. note:: + The blended transformations where x is in data coords and y in axes + coordinates is so useful that we have helper methods to return the + versions mpl uses internally for drawing ticks, ticklabels, etc. + The methods are :meth:`matplotlib.axes.Axes.get_xaxis_transform` and + :meth:`matplotlib.axes.Axes.get_yaxis_transform`. So in the example + above, the call to + :meth:`~matplotlib.transforms.blended_transform_factory` can be + replaced by ``get_xaxis_transform``:: + + trans = ax.get_xaxis_transform() + .. offset-transforms-shadow: Using offset transforms to create a shadow effect ================================================= One use of transformations is to create a new transformation that is -offset from another annotation, eg to place one object shifted a bit -relative to another object. Typically you want the shift to be in +offset from another transformation, eg to place one object shifted a +bit relative to another object. Typically you want the shift to be in some physical dimension, like points or inches rather than in data coordinates, so that the shift effect is constant at different zoom levels and dpi settings. @@ -301,8 +313,11 @@ shadow_transform = ax.transData + offset showing that can chain transformations using the addition operator. -This code says: first apply the data transformation ``ax.transData`` and -then translate the data by `dx` and `dy` points. +This code says: first apply the data transformation ``ax.transData`` +and then translate the data by `dx` and `dy` points. In typography, +a`point <http://en.wikipedia.org/wiki/Point_%28typography%29>`_ is +1/72 inches, and by specifying your offsets in points, your figure +will look the same regardless of the dpi resolution it is saved in. .. plot:: :include-source: This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------------ Download new Adobe(R) Flash(R) Builder(TM) 4 The new Adobe(R) Flex(R) 4 and Flash(R) Builder(TM) 4 (formerly Flex(R) Builder(TM)) enable the development of rich applications that run across multiple browsers and platforms. Download your free trials today! http://p.sf.net/sfu/adobe-dev2dev _______________________________________________ Matplotlib-checkins mailing list Matplotlib-checkins@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins