Commits

Joon Ro committed 887a706

* Updates

  • Participants
  • Parent commits e94bae7

Comments (0)

Files changed (4)

    pytables
    unicode
    web-crawling
+   resources
 
 
 Indices and tables
-matplotlib
-==========
+============
+ matplotlib
+============
 
 ..highlight:: python
 
+``mpltools``: Tools for Matplotlib
+==================================
+
+http://tonysyu.github.io/mpltools/
+
+``mpltools`` provides tools for Matplotlib that make it easier to adjust the
+style, choose colors, make specialized plots, etc.
+
+
+
+
 dates
------
+=====
 
 .. code-block:: python
 
    ax.xaxis.set_minor_locator(weeks)
 
 LaTeX
------
+=====
 
 .. code-block:: python
 
    plt.text(0.05, 0.90, r'\underline{\alpha}: ', fontsize=12)
 
 Subplots
---------
+========
 
 .. code-block:: python
 
    fig.tight_layout()  # narrow margin
 
 Save to PDF
------------
+===========
 
 .. code-block:: python
 
-Profiling
-=========
+===========
+ Profiling
+===========
 
 Get the profile stats with ``cProfile``
------------------------------------------
+=======================================
 
 .. code-block:: python
 
    prof.dump_stats('stats.prof')
 
 
-``RunSnakeRun``
----------------
+``RunSnakeRun`` to visualize the profile stats
+----------------------------------------------
 
 Install `RunSnakeRun <http://www.vrplumber.com/programming/runsnakerun/>`_ for
-GUI view:
+GUI view::
 
-.. code-block:: sh
+   $ pip install RunSnakeRun
+
+It needs `wxPython <http://www.wxpython.org/>`_::
 
-   $ zypper in RunSnakeRun
+   $ conda install wxpython
 
 Invoke ``RunSnakeRun``:
 
 
    $ runsnake stats.prof
 
+* It is useful to look at ``Local`` column. This gives the time spent on a
+  function itself, excluding the time spent calling other functions during the
+  function call. Hence it gives the *net* time spent.
 
-``KCachegrind`` with ``pyprof2calltree``
-----------------------------------------
+* On the other hand, ``Cum`` shows the cumulative time spent on that function,
+  including the time spent for other function calls made during the function
+  call.
 
-Install ``KCachegrind`` and ``pyprof2calltree``:
 
-.. code-block:: sh
+``KCachegrind`` with ``pyprof2calltree``
+========================================
+
+Install ``KCachegrind`` and ``pyprof2calltree``::
 
    $ zypper in kcachegrind
    $ sudo pip install pyprof2calltree
 
-Invoke ``KCachegrind`` through ``pyprof2calltree``:
-
-.. code-block:: sh
+Invoke ``KCachegrind`` through ``pyprof2calltree``::
 
    $ pyprof2calltree -i stats.prof -k
+===========
+ Resources
+===========
+
+* `The Hitchhiker’s Guide to Python!
+  <http://docs.python-guide.org/en/latest/>`_
+* `Python Testing Frameworks <http://pythontesting.net/start-here/>`_