Welcome to iraf.net Friday, May 10 2024 @ 12:55 AM GMT
chewbacca |
07/17/2014 09:18PM (Read 2857 times)
|
|
|
Status: offline
Registered: 07/17/2014
Posts: 14
|
Hi,
I have a raw spectrum to which I want to assign a wavelength solution (dispersion function).
I know the standard way to do this is to run identify on a lamp spectra to fit a dispersion function, and then assign such a file to the field REFSPEC1 of the image I want to wavelength-calibrate, and then run dispcor.
In my case, however, I already have a vector containing the wavelength vs pixel information (so I don't have/need arc lamp data). What I want is then to fit a dispersion function to this data and assign that as the dispersion function of my science image.
What is the best way to do this?
Thanks,
Chewbacca
|
|
|
|
valdes |
07/25/2014 05:23PM
|
|
|
Status: offline
Registered: 11/11/2005
Posts: 728
|
The way to do this is to produce a text file with columns for the wavelength and flux values. The two tasks that can aid you in this are wspectext and rspectext. You could use wspectext to make a file in the appropriate format with the keywords or listpix to just dump the flux values. Pasting your separate wavelength values next to the flux values is an exercise for the reader but it could involve and editor, the join task, writing a simple script or using the nttools package.
Once you have the wavelength and flux values in a text file the rspectext command can make an IRAF 1D spectrum. You have the option to linearize the wavelength values, kind of like doing a dispcor, or keeping the wavelength values as a look up table.
This is a little brief but if you have questions feel free to ask.
Frank Valdes
|
|
|
|
chewbacca |
07/25/2014 08:09PM
|
|
|
Status: offline
Registered: 07/17/2014
Posts: 14
|
Alright, thanks!
I managed to get it working alternatively with scoords to assign a wavelength value for each pixel and then dispcor to relinearize the spectra.
|
|
|
|
valdes |
07/25/2014 08:40PM
|
|
|
Status: offline
Registered: 11/11/2005
Posts: 728
|
That's news to me. Thanks for sharing. Frank
|
|
|
|
| |
|
Content generated in: 0.11 seconds |
|