PyRAF is installed on the classroom linux machines using the astroconda setup. You do not need to install astroconda or PyRAF on your own machine (unless you want to).
Upon opening any new terminal window, remember to ALWAYS type these two commands to start:
Also, I highly
recommend you set up your linux environment so that you make windows
active by mousing over them (the default click-to-activate setup is a
crime against humanity). To do this, at the top of your screen,
do System --> Preferences --> Windows and then click Select windows when mouse moves over them.
- bash (if you are not already in a bash terminal)
- source activate iraf27
The first time you set up to run PyRAF, first do the following:
- cd (to make sure you in your home directory)
Quitting pyraf: .exit (that's dot-exit)
- cd (to make sure you in you always start pyraf from your home directory)
- then move to whatever directory your data is in (cd <datadir>)
- from the pyraf command line, start ds9: !ds9 &
Miscellaneous tips, as I think of them:
use pyraf's display task to display images. That task is outdated and
does not play well with ds9. ALWAYS open images directly from ds9.
- To edit pyraf task parameters:
- Option 1: epar <task>
will open up a new window that allows you to view and edit the
parameters. Good if your not sure which parameter you need or what the
allowed values are.
- Option 2: if you already know what you need to set a parameter to, from the pyraf command prompt you can set it by typing iraf.<task>.<parameter> = <value>
- If you have a file where the first two lines are x,y image
coordinates, you can overplot those positions in ds9 by going to
Region -> Load Region,
clicking All, and then
choosing the file. When the load window pops up, tell it that
the file format is xy
and that the coordinate system is image. (if you had a file of ra & dec, you
could tell it the coordinate system is wcs....)
- In any command that wants to know certain keywords from the
image header, exposure time is EXPTIME, airmass is AIRMASS, and
obstime is DATE-OBS. If you set these this way, you'll be
happier. You can always see what's in the image header by
loading the image into ds9 (don't
display it through IRAF) and choosing File->Display Fits Header.