Is python a good choice for this task?

Fernando Pérez fperez528 at yahoo.com
Mon Nov 11 15:51:25 EST 2002


Ron Lau wrote:

> My question is, What language is best suited for this? Perl, Python, or
> shell scripts?

Well, from each of the groups you posted to you'll get a different answer. But 
of course, two of them will be wrong. You should use python :)

Kidding aside, such a simple task can be done in any of those without any 
effort. I'd still suggest python because it's a better language than the 
others for a number of things (yes, I've used all three extensively). 
Especially if you have a scientific computing background: if you poke around 
the web a bit, you'll find that python is becoming very popular in scientific 
computing circles, and for good reason. See http://scipy.org/ or  
http://mayavi.sourceforge.net/ for useful things in this direction.

The task you described will hardly illustrate the differences between these 
languages. But when you decide you want to control your fortran CFD code 
through a high-level language, load NetCDF or HDF5 data files, visualize them 
with VTK, generate webpages out of the plot results, python will really begin 
to shine. I recommend you read: 
http://www.python.org/workshops/1997-10/proceedings/beazley.html before 
making this decision. It's written from the viewpoint of a scientific 
computing person, and while a bit old, it remains almost 100% true today. The 
parts that have changed is simply that many of the tasks described in that 
article are _far_ easier to do today than they were then.

Welcome!

f.

ps. Other useful links for python and scientific computing:
http://www.pfdubois.com/numpy/
http://starship.python.net/crew/hinsen/
http://w3.pppl.gov/~hammett/comp/python/python.html




More information about the Python-list mailing list