Changes between Version 18 and Version 19 of Wisdom/Python


Ignore:
Timestamp:
03/12/13 11:00:38 (13 years ago)
Author:
jps@…
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Wisdom/Python

    v18 v19  
    6767Note that unlike IDL, Python's instantiation of lists and arrays is by reference rather than by value. For people who have used IDL for many moons, this may cause headaches. The workarounds are worth taking some time to consider carefully: [http://stackoverflow.com/questions/8744113/python-list-by-value-not-by-reference read this for more].
    6868
     69Another difference between IDL and Python, in the interactive mode, is that once you load a package or a module it stays loaded in the form you first indicated even if you say
     70
     71> > > import <blah>
     72
     73all over again. This is unlike in IDL where if you say
     74
     75> > >.run <blah>
     76
     77it will reload all of your programming along with any changes you made.
     78
     79To "reload" a package in interactive Python you, somewhat unsurprisingly, use:
     80
     81> > > reload(<blah>)
     82
    6983
    7084=== Astropy ===