IPython Bookshttp://ipython-books.github.io/2015-11-01T00:00:00+01:00New edition of the IPython Minibook2015-11-01T00:00:00+01:00Cyrille Rossanttag:ipython-books.github.io,2015-11-01:minibook-new-edition/<p>The <a href="https://www.packtpub.com/big-data-and-business-intelligence/learning-ipython-interactive-computing-and-data-visualization-sec">new edition of the IPython Minibook</a> has just been released!</p>
<p>What's new in this edition:</p>
<ul>
<li>It makes a greater emphasis on <strong>data analysis with pandas and NumPy</strong>.</li>
<li>There are clear step-by-step instructions for <strong>beginners with no programming experience</strong>.</li>
<li>The code now uses <strong>Python 3</strong>, <strong>IPython 4.0</strong>, and the <strong>Jupyter Notebook</strong>.</li>
<li>There is a new <strong>introduction to the Python language</strong> for beginners.</li>
<li>Most of the contents have been rewritten, and almost all code examples are new.</li>
<li>There are examples of advanced Notebook features like <strong>interactive widgets</strong> and web-based visualization tools like <strong>D3.js</strong>.</li>
<li>As in the previous edition, there are contents for more advanced readers, like <strong>Numba, Cython, and parallel computing with IPython</strong>.</li>
</ul>
<p>You will find more details on the <a href="/minibook/">Minibook page</a>.</p>
<p>You can buy the ebook or paperback edition on <a href="https://www.packtpub.com/big-data-and-business-intelligence/learning-ipython-interactive-computing-and-data-visualization-sec">Packt Publishing</a> or <a href="http://www.amazon.com/Learning-IPython-Interactive-Computing-Visualization-ebook/dp/B014T58NBO/ref=sr_1_2?s=digital-text&ie=UTF8&qid=1445850768&sr=1-2&keywords=learning+ipython">Amazon</a>.</p>
<p>Happy reading!</p>Featured recipes2014-10-14T00:00:00+02:00Cyrille Rossanttag:ipython-books.github.io,2014-10-14:featured-recipes/<p>The <a href="/cookbook/">IPython Cookbook</a> contains more than <a href="/cookbook/#part-i-advanced-high-performance-interactive-computing">100 recipes on numerical computing and data science with Python</a>. The integrality of the code is <a href="https://github.com/ipython-books/cookbook-code">freely available on GitHub</a>. In addition, I have released several <strong>featured recipes</strong> so far. These recipes contain not only the code, but also the full recipe description, the explanations, and all references. They cover a wide range of the topics covered in the book. I intend to release more featured recipes in the future.</p>
<p>Here are the six featured recipes available today:</p>
<ol>
<li>
<p><a href="/featured-01/"><strong>Getting the best performance out of NumPy</strong></a>. This recipe elaborates on a blog post I had written a while ago. It gives a few tricks that can make your NumPy code much more efficient. I also explain a few implementation details of NumPy that you need to know in order to get the best performance out of your code.</p>
<p><img alt="NumPy array layout." src="http://ipython-books.github.io/images/layout.png" /></p>
</li>
<li>
<p><a href="/featured-02/"><strong>Simulating a physical system by minimizing an energy</strong></a>. This recipe illustrates how to use SciPy's optimization routines to simulate a physical system.</p>
<p><img src="http://ipython-books.github.io/images/optim.png" alt="NumPy array layout." width="300" /></p>
</li>
<li>
<p><a href="/featured-03/"><strong>Creating a route planner for road network</strong></a>. This recipe implements a GPS-like itinerary planner in pure Python! It uses the <a href="http://networkx.github.io">NetworkX package</a> to compute a shortest path in a road network. The example uses an open dataset with the full road network of California.</p>
<p><img alt="A GPS in Python!" src="http://ipython-books.github.io/images/road.jpg" /></p>
</li>
<li>
<p><a href="/featured-04/"><strong>Introduction to machine learning in Python with scikit-learn</strong></a>. This recipe illustrates the most fundamental concepts of machine learning with scikit-learn. This is the recipe for you if you're just getting started with machine learning, and you want to understand the meaning of supervised and unsupervised learning, classification, regression, clustering, feature selection, feature extraction, overfitting, regularization, and cross-validation. This recipe illustrates some of these concepts on a simple curve fitting problem, using least squares and ridge regression.</p>
<p><img src="http://ipython-books.github.io/images/ml.png" alt="Introduction to scikit-learn" width="600" /></p>
</li>
<li>
<p><a href="/featured-05/"><strong>Simulating a partial differential equation (PDE): reaction-diffusion systems and Turing patterns</strong></a>. This recipe shows how to simulate a PDE in Python and NumPy, using the finite difference method.</p>
<p><img src="http://ipython-books.github.io/images/turing.jpg" alt="Turing patterns in Python" width="400" /></p>
</li>
<li>
<p><a href="/featured-06/"><strong>Getting started with Vispy</strong></a>. This recipe illustrates the fundamental concepts of OpenGL for big data visualization using <a href="http://vispy.org">Vispy</a>, a Python library I've been working on for nearly two years.</p>
<p><img alt="Vispy examples" src="http://ipython-books.github.io/images/vispy.jpg" /></p>
</li>
<li>
<p><a href="/featured-07/"><strong>Introduction to statistical data analysis in Python – frequentist and Bayesian methods</strong></a>. This recipe introduces the basis of frequentist and Bayesian methods for statistical data analysis, using a simple coin tossing example.</p>
<p><img src="http://ipython-books.github.io/images/gaussian.png" alt="A z-test" /></p>
</li>
</ol>
<p>I'm planning to release more featured recipes in the near future. <a href="https://twitter.com/cyrillerossant">Let me know</a> if there's one recipe in particular you'd like to see among <a href="/cookbook/#part-i-advanced-high-performance-interactive-computing">all of the cookbook's recipes</a>.</p>prettyplotlib is no longer being developed2014-10-11T00:00:00+02:00Cyrille Rossanttag:ipython-books.github.io,2014-10-11:prettyplotlib-no-longer-being-developed/<p><a href="https://github.com/ipython-books/cookbook-code/issues/12">Github issue #12</a>.</p>
<p>prettyplotlib is covered in <a href="http://nbviewer.ipython.org/github/ipython-books/cookbook-code/blob/master/notebooks/chapter06_viz/01_prettyplotlib.ipynb">recipe 6.1</a>. However, <a href="http://www.olgabotvinnik.com/">Olga Botvinnik</a> (<a href="https://github.com/olgabot">@olgabot</a>) <a href="http://blog.olgabotvinnik.com/blog/2014/10/06/no-longer-actively-developing-prettyplotlib/">is no longer actively developing this library</a>.</p>
<p>If you are interested in similar features for improving matplotlib's styling, you can:</p>
<ul>
<li>Use <a href="http://matplotlib.org/users/style_sheets.html">matplotlib stylesheets</a>, new in matplotlib 1.4</li>
<li>Use <a href="http://web.stanford.edu/~mwaskom/software/seaborn/">seaborn</a>, actively maintained by <a href="http://stanford.edu/~mwaskom/">Michael Waskom</a> (<a href="https://github.com/mwaskom">@mwaskom</a>)</li>
</ul>New Microsoft C++ compiler for Python 2.7 on Windows2014-09-29T00:00:00+02:00Cyrille Rossanttag:ipython-books.github.io,2014-09-29:windows-compiler/<p>Compiling C extensions for Python on Windows used to be complicated. One had to install the adequate (unsupported) versions of Microsoft Visual Studio and the Windows compilers. Furthemore, it was necessary to invoke some commands on the command-line interface before running Python or IPython. In the end, installing non-pure-Python packages, or building non-pure-Python distributions for Windows users was a pain.</p>
<p>Microsoft is now trying to simplify this task by releasing a compiler package specifically targetting Python 2.7. This means that it should be much easier to compile C extensions for Python 2.7 on Windows now.</p>
<p>You will find an <a href="http://code.activestate.com/lists/python-dev/132763/">unofficial announcement by Microsoft here</a>, and the <a href="http://www.microsoft.com/en-us/download/details.aspx?id=44266">compiler package here</a>.</p>
<p>The instructions to compile C extensions on Windows that you'll find in the IPython minibook and cookbook should still be valid, but they're likely to be soon superseded by simpler instructions based on this new compiler package.</p>IPython Cookbook released2014-09-26T00:00:00+02:00Cyrille Rossanttag:ipython-books.github.io,2014-09-26:ipython-cookbook-released/<p>My new book, <a href="/cookbook/">IPython Interactive Computing and Visualization Cookbook</a>, has just been released! A sequel to my previous <a href="http://ipython.rossant.net">beginner-level book on Python for data analysis</a>, this new 500-page book is a <strong>complete advanced-level guide to Python for data science</strong>. The 100+ recipes cover not only interactive and high-performance computing topics, but also data science methods in statistics, data mining, machine learning, signal processing, image processing, network analysis, and mathematical modeling.</p>
<p>Here is a glimpse of the topics addressed in this book: </p>
<ul>
<li>IPython notebook, <strong>interactive widgets</strong> in IPython 2+</li>
<li>Best practices in interactive computing: version control, workflows with IPython, testing, debugging, continuous integration...</li>
<li>Data analysis with pandas, NumPy/SciPy, and matplotlib</li>
<li>Advanced data visualization with <strong>seaborn, Bokeh, mpld3, d3.js, Vispy</strong>...</li>
<li>Code profiling and optimization</li>
<li>High-performance computing with <strong>Numba, Cython, GPGPU with CUDA/OpenCL, MPI, HDF5, Julia</strong>...</li>
<li>Statistical data analysis with <strong>SciPy, PyMC, R</strong>...</li>
<li>Machine learning with <strong>scikit-learn</strong></li>
<li>Signal processing with SciPy, image processing with <strong>scikit-image</strong> and OpenCV</li>
<li>Analysis of graphs and social networks with <strong>NetworkX</strong></li>
<li>Geographic Information Systems in Python</li>
<li>Mathematical modeling: dynamical systems, symbolic mathematics with <strong>SymPy</strong></li>
</ul>
<p>All of the code is freely available as IPython notebooks on the <a href="https://github.com/ipython-books/cookbook-code">book's GitHub repository</a>. This repository is also the place where you can signal errata or propose improvements to any part of the book.</p>
<p>The book uses Python 3, although most of the code will work fine on Python 2.</p>
<p>You'll find the book on <a href="https://www.packtpub.com/big-data-and-business-intelligence/ipython-interactive-computing-and-visualization-cookbook">Packt's website</a>, <a href="http://www.amazon.com/IPython-Interactive-Computing-Visualization-Cookbook/dp/1783284811/ref=sr_1_1?s=books&ie=UTF8&qid=1410688253&sr=1-1">Amazon</a>, and many other bookstores.</p>IPython Minibook released2013-04-27T00:00:00+02:00Cyrille Rossanttag:ipython-books.github.io,2013-04-27:ipython-minibook-released/<p>I'm glad to present my new book, <a href="/minibook/">Learning IPython for Interactive Computing and Data Visualization</a>, Packt
Publishing.</p>
<p>This book is a <strong>beginner-level introduction to IPython</strong> for
interactive Python programming, high-performance numerical computing,
and data visualization. It assumes nothing more than familiarity with
Python. It targets developers, students, teachers, hobbyists who know
Python a bit, and who want to learn IPython for the extended console,
the Notebook, and for more advanced scientific applications.</p>
<p>The book first introduces IPython for interactive Python and shell
programming. It shows how IPython can considerably improve the
productivity of a developer who creates, debugs, benchmarks and profiles
Python code.</p>
<p>Then, the reader learns the very basics of vector computing, and
discovers how to load and analyze numerical and tabular data with NumPy
and Pandas. The book shows the interactive visualization capabilities of
the platform with Matplotlib, SciPy and PIL. It also contains a few
image processing examples.</p>
<p>Some techniques to accelerate Python code are also demonstrated, using
either interactive parallel computing features from IPython (using MPI
or not), or Cython to compile a portion of the code in C for really
interesting speedups.</p>
<p>Finally, the book shows how IPython can be customized for advanced uses,
notably with the creation of new extensions and magic commands.</p>
<p>The code is stored in a <a href="https://github.com/rossant/ipython-minibook">GitHub
repository</a>. It contains
IPython notebooks with most examples from the book.</p>