comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Top 10 IDL Requests ... python
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: Top 10 IDL Requests ... python [message #20977] Thu, 03 August 2000 00:00 Go to next message
Kristian Kjaer is currently offline  Kristian Kjaer
Messages: 58
Registered: June 1998
Member
> "Paul van Delst" <pvandelst@ncep.noaa.gov> wrote in message
> news:398825D1.B3B3F605@ncep.noaa.gov...
>
>> It won't make me stop using IDL, but I find it hard to counter his
>> argument when he can do in Python pretty much everything I can in
>> IDL.
>
Mark Hadfield wrote:
> Can he really? Even graphics? Perhaps I'd better take another look at
> Python!

Can all our existing *.pro files be used with python?
If not, would it be easy to convert them?

- Kristian Kjær, Risø Natl. Laboratory, Denmark
Re: Top 10 IDL Requests ... python [message #21045 is a reply to message #20977] Fri, 04 August 2000 00:00 Go to previous message
Paul van Delst is currently offline  Paul van Delst
Messages: 364
Registered: March 1997
Senior Member
Mark Hadfield wrote:
>
> "Kristian Kjaer" <Kristian.Kjaer@Risoe.Dk> wrote in message
> news:3989B2D1.8A3D3153@Risoe.Dk...
>> Can all our existing *.pro files be used with python?
>> If not, would it be easy to convert them?
>
> I'm afraid the answers are NO and NO. It's a completely different language.
> The scientific graphics subsystem is--from the little I know about
> it--completely different from either direct or object graphics.

He's using python but what he's developing he calls PYDL, i.e. an
interpreter that runs within Python. Some sample command line code:

PYDL> x = dindgen(100)/100.0 * 4.0 * pi
PYDL> y1 = sin(x)
PYDL> y2 = cos(x)
PYDL> set_plot('ps')
PYDL> device(file='nicks_test.ps')
PYDL> plot(x,y1, xtitle='Theta',ytitle='SIN/COS', \
title='Trigonometry Functions', \
nodata=1, xrange=[0,12])
PYDL> oplot(x,y1, color=2)
PYDL> oplot(x,y2, color=3)
PYDL> device(close=1)

I think most IDL programmers will recognise what's going on. He always
told me he disliked the IDL syntax punctuation - hence the use of "()"
instead of the ",", e.g. plot(x,y) instead of plot, x, y.

Personally I never understood why this bothered people. Doesn't C
require a ";" at the end of each line?

Same dog, different leg I reckon.

paulv
--
Paul van Delst Ph: (301) 763-8000 x7274
CIMSS @ NOAA/NCEP Fax: (301) 763-8545
Rm.202, 5200 Auth Rd. Email: pvandelst@ncep.noaa.gov
Camp Springs MD 20746
Re: Top 10 IDL Requests ... python [message #21062 is a reply to message #20977] Fri, 04 August 2000 00:00 Go to previous message
Mark Hadfield is currently offline  Mark Hadfield
Messages: 783
Registered: May 1995
Senior Member
"Kristian Kjaer" <Kristian.Kjaer@Risoe.Dk> wrote in message
news:3989B2D1.8A3D3153@Risoe.Dk...
> Can all our existing *.pro files be used with python?
> If not, would it be easy to convert them?

I'm afraid the answers are NO and NO. It's a completely different language.
The scientific graphics subsystem is--from the little I know about
it--completely different from either direct or object graphics.

---
Mark Hadfield
m.hadfield@niwa.cri.nz http://katipo.niwa.cri.nz/~hadfield/
National Institute for Water and Atmospheric Research
PO Box 14-901, Wellington, New Zealand
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Strange PRINTER Coordinates
Next Topic: ascii_template

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 19:30:24 PDT 2025

Total time taken to generate the page: 0.00413 seconds