Adding a WCS to your fits image

So, adding a WCS is not actually all that difficult. But in my experience finding the process clearly explained is more challenging. I finally found a process that works well for me (with thanks going to Kyle Johnston, U. Waterloo, for outlining the process). Also, there are probably multiple ways to do this, but here is my attempt to lay it out clearly. I hope it helps!

(for a more formatted version, try this pdf file)

Steps for Adding a WCS to your FITS image:

Continue reading

But it’s so comforting…

So, today I needed to perform a Kolmogorov Smirnov two-sample test, and I had to refresh my memory a bit on the details. Given that I just moved overseas, most of my notes are tucked away in Kansas City at the moment, so I turned to the web.

In Wikipedia-ing my way back to restoring my memory, I stumbled upon this quote about testing null-hypotheses that made me laugh. It describes it as “mindless statistics” and “a ritual conducted to convince ourselves that we have the evidence needed to confirm our theories.”

Trim.pro

I just remembered you’ll need this beauty in order to run hfit.pro

I like to use IDL to make nicely formatted tables or listings of data to drop into, say, latex or other software. One of my pet peeves in IDL is that the numbers always give a large number of digits, and there are leading spaces. So, a while back I wrote trim.pro to take care of this. It’s very handy!

e.g. if x = 5.43961

print, trim(x,2) yields 5.44 (it rounds, rather than truncates)

you can find it here.

enjoy!

Hubble Profile Script

Here’s a useful little script I wrote in IDL. It allows you to send it 2 arrays (x and y data) and then you can plot the data, and fit it with a Hubble profile:

y = I * (1 + x/r_c)^(-a)

where I, r_c and a are constants representing the vertical scaling, the core radius and the exponent of decline, respectively.

It’s interactive, and allows you to adjust parameters and re-fit on the fly.

Click here to download it.

How to prepare a Mac for Astrophysical Research

  • Change to tcsh

    So, by default, OSX runs the bash shell at the command prompt. However, most astronomers tend to prefer tcsh. Probably this is because iraf expects tcsh. There are some excellent instructions on how to switch to tcsh at Mark Westmoquette’s Apple Mac pages, so I won’t repeat them here.

    http://spac-21.rice.edu/maciraf/tips/panther/change_shell.txt

  • X11

    This software usually comes on one of your OSX CD’s. If I remember right, it’s kind of buried on disk one, but it’s been awhile… if you have trouble finding it, it’s also available from:

    http://www.apple.com/downloads/macosx/apple/x11formacosx.html

  • XCode

    Not strictly necessary, but if you ever need to compile things from source code, you’ll need this software. I install it because various items in fink (see below) sometimes don’t have binaries — only source code. So, this is needed for Fink to do its thing.

    It can be found on Apple’s webpage, although I think you need to register (it’s free) to download it.

    http://developer.apple.com/tools/download/

  • Fink

    The Fink project was created with the goal of modifying Unix software so that it compiles and runs on the Mac. Basically it provides a mechanism to easily install all your unix favourites, such as Gimp, ghostview (gv) and xv on your mac. Fink needs to be installed and can be used by itself. However, Fink Commander makes it even easier to install individual packages, so personally I like to use this add-on.

    First, download and install Fink. You can read more about Fink here:

    http://fink.sourceforge.net/

    The actual download files and some nice instructions (for the whole fink process) can be found here:

    http://fink.sourceforge.net/download/

    When you install fink, it will create a /sw/ directory. There are some instructions in the readme – I think about adding some things to your .cshrc file. In my .cshrc file, I have the line:

    test -r /sw/bin/init.csh && source /sw/bin/init.csh

    and, I added /sw/bin to my path.

    Next, download and install Fink Commander, and use it to upgrade Fink. You can find a disk image and some instructions on Fink Commander here:

    http://finkcommander.sourceforge.net/

    Click here to see a screenshot of fink updating fink.

  • Scisoft

    Scisoft is a package containing almost every piece of software useful in astronomy. Currently it’s an almost 900 Mb but absolutely worth it. It contains favourites such as IRAF, MIDAS, and more.

    The actual SciSoft package is produced by ESO but another group has taken that package and compiled it for Mac OSX. You can find their webpage here:

    http://web.mac.com/npirzkal/iWeb/Scisoft/Scisoft.html

    It’s a simple download an installation. Basically you click your way through their install package, and then you add a few lines to your .cshrc file. They have detailed instructions, along with screenshots, which you can find here:

    http://web.mac.com/npirzkal/iWeb/Scisoft/Installing.html

    and the file can be downloaded from here:

    http://www.versiontracker.com/dyn/moreinfo/macosx/20126

    This site also has a list of what Scisoft contains.