Tiny Tutorial 3: Intro to Plotting in Python with Matplotlib

Publicado el: 24 agosto 2017
en el canal de: Enthought
3,430
29

Matplotlib is an open source plotting library for the Python programming language. Matplotlib is both versatile and powerful - with it you can create everything from simple quick-and-dirty exploratory plots to very complex, publication-quality figures.

The online documentation (https://matplotlib.org) includes an extensive gallery of sample plots. This is a great starting point for your own plots - scroll through and find something similar to what you need, copy and paste the code into your editor, and - voila! - you can re-create that plot on your machine, and then modify it to suit your specific needs.

This is a really nice interactive way to work: go look for something that looks like what you want to do and then run it immediately in Canopy (https://www.enthought.com/product/can...) or another editor and play with it.

Now that you have the plot you can make some changes on the fly before you save it as an image to include in your document. For example, you can add grid lines by using the shortcut (g) or press it again to remove them. You can zoom into the plot by clicking and dragging to zoom in on the section you want to look at more closely, press (h) or escape to go back to the zoomed out view.

You can also add titles quickly in the figure options. Add the title and you can also change the scale within it. Click apply and there you go. You can make more simple adjustments on the fly and when you are ready to save press (s).

Now save your image where you want in the file format that you want. You can choose from a range of options, from jpg and png to pdf, even eps and svg.

That’s a quick look at what matplotlib can do and how easy it can be to get started, but that's just the tip of the iceberg.

Be sure to subscribe to the Enthought YouTube channel to keep up with the videos in the Tiny Tutorial series, to learn more about what you can do with this powerful, open source visualization tool.

**Learn more about Enthought's Python course offerings here:
https://goo.gl/rk1ouD


En esta página del sitio puede ver el video en línea Tiny Tutorial 3: Intro to Plotting in Python with Matplotlib de Duración hora minuto segunda en buena calidad , que subió el usuario Enthought 24 agosto 2017, comparta el enlace con amigos y conocidos, en youtube este video ya ha sido visto 3,430 veces y le gustó 29 a los espectadores. Disfruta viendo!