Page - 217 - in Programming for Computations β Python - A Gentle Introduction to Numerical Simulations with Python
Image of the Page - 217 -
Text of the Page - 217 -
A.5 WritingIPythonNotebooks 217
Executing these statements results in a plot in the browser, see Fig. A.2. It was
popular tostart thenotebookbyipython notebook βpylab to importeverything
from numpy and matplotlib.pyplotandmake all plots inline, but the βpylab
option isnowofficiallydiscouraged18. Ifyouwant thenotebook tobehavemoreas
MATLABandnotuse thenpandpltprefix,youcan insteadof thefirst three lines
abovewrite%pylab.
Fig.A.2 Exampleonan IPythonnotebook
18http://carreau.github.io/posts/10-No-PyLab-Thanks.ipynb.html
back to the
book Programming for Computations β Python - A Gentle Introduction to Numerical Simulations with Python"
Programming for Computations β Python
A Gentle Introduction to Numerical Simulations with Python
- Title
- Programming for Computations β Python
- Subtitle
- A Gentle Introduction to Numerical Simulations with Python
- Authors
- Svein Linge
- Hans Petter Langtangen
- Publisher
- Springer Open
- Date
- 2016
- Language
- English
- License
- CC BY-NC 4.0
- ISBN
- 978-3-319-32428-9
- Size
- 17.8 x 25.4 cm
- Pages
- 248
- Keywords
- Programmiersprache, Informatik, programming language, functional, imperative, object-oriented, reflective
- Category
- Informatik