Thread
:
[Announce] MatPlotLib  2D & 3D plots for MeeGo Harmattan
View Single Post
rcolistete
11262011 , 02:21 PM
Posts: 854  Thanked: 1,943 times  Joined on May 2011 @ Brazil
#
4
Here are some useful examples/templates scripts for ploting with MatPlotLib/NumPy. They have many options to change : domain, function, labels, title, etc. To adapt them to your use, just open the .py file with a text editor (for example Nano for Nokia N9 in Nokia Store), change the definitions in the section "# Personalize your plot parameters here", save and run (using Terminal) :
$ python <scriptname>.py
Timings for MatPlotLib 1.2.0 and NumPy 1.4.1 on Nokia N9.
plotfx.py : Plot of one variable, f=f(x), saving to a (PNG) file. Takes 8.4 s on Nokia N9.
contourfxy.py : contour plot of two variables, f=f(x,y), saving to a (PNG) file. Takes 10.2 s on Nokia N9.
densityfxy.py : density shaded relief plot of two variables, f=f(x,y), saving to a (PNG) file. Takes 10.3 s on Nokia N9.
vectorfieldFxy.py : vector field plot in 2D, F=F(x,y), saving to a (PNG) file. Takes 8.2 s on Nokia N9.
surfacefxy.py : surface plot of two variables, f=f(x,y), saving to a (PNG) file. Takes 16.6 s on Nokia N9.
__________________
Python, C/C++, Qt and CAS developer. For Maemo/MeeGo :
Integral
,
Derivative
,
Limit
 calculating mathematical integrals, derivatives and limits.
SymPy
 Computer Algebra System.
MatPlotLib
 2D & 3D plots in Python.
IPython
 Python interactive shell.
PyGlet
 OpenGL, etc in Python.

My blog about mobile & scientific computing

2 Nokia N9
16GB Black @ 1.35 GHz with Easy Debian, 1 with Sailfish, Stowaway foldable BT keyboard.
Nokia N900
@ 1.1 GHz, EasyDebian, NITDroid 2.2.
N810
with cloned Maemo on SD, EasyDebian.
Last edited by rcolistete; 02112013 at
12:42 PM
. Reason: Timings for MatPlotLib 1.2.0.
Quote & Reply

The Following 6 Users Say Thank You to rcolistete For This Useful Post:
aRTee
,
Joseph9560
,
lolloo
,
StefanL
,
vielfrass
,
Wikiwide
rcolistete
View Public Profile
Send a private message to rcolistete
Visit rcolistete's homepage!
Find all posts by rcolistete