How to convert fits file into ASCII file using IRAF?
nishahansraj wrote on Nov 10, 2009
I have a fits file. It is actually a spectra. When I use splot <filename>.fits I get a plot of spectra of an object which is normalized amplitude (y-axis) versus wavelength (x-axis). I would like to extract the data, get two columns one which would give me normalized amplitude in the range of 0-1 while the other column will give me wavelength. I would like to know how I can do that in IRAF.
nishahansraj wrote on Nov 10, 2009
I used wtextimage...But it gives me the following error:
cl> wtextimage
Input image file: lwr05969mxhi.fits
Output text file: lwr05969.txt
Unable to open parameter file `uparm$daowtexte.par'
Can you tell whats the problem?
cl> wtextimage
Input image file: lwr05969mxhi.fits
Output text file: lwr05969.txt
Unable to open parameter file `uparm$daowtexte.par'
Can you tell whats the problem?
Mike Fitzpatrick wrote on Nov 10, 2009
The MINMAX task will find the max value of the spectrum, divide by that to produce the normalized spectrum, them WSPECTEXT to write the ascii output.
Your message about the uparm problem either means the uparm directory doesn't exist or you can't write to it, e.g. you copied a login.cl from another machine or logged in using another user's login.cl. A new MKIRAF should fix it, the task still ran but the parameters were saved.
-Mike[/url]
Your message about the uparm problem either means the uparm directory doesn't exist or you can't write to it, e.g. you copied a login.cl from another machine or logged in using another user's login.cl. A new MKIRAF should fix it, the task still ran but the parameters were saved.
-Mike[/url]
nishahansraj wrote on Nov 10, 2009
Where can i find MINIMAX task in iraf package?
Mike Fitzpatrick wrote on Nov 10, 2009
MINMAX (not minImax) is part of the default IMUTIL package and should be visible when you log in.
anubu wrote on Nov 10, 2009
When I use WSPECTEXT to convert my fits spectra into an ascii file, the result is just a column with the intensity values of the spectra, but the wavelength values aren't there.
Mike Fitzpatrick wrote on Nov 10, 2009
Does the SLIST task see a valid spectral WCS in the image? WSPECTEXT is basically a script wrapper about the LISTPIXELS task to dump the values, but even without a WCS you should still see the pixel number in the output. Could you post the spectra's header or else upload the image to ftp://iraf.noao.edu/pub?
starryeyed wrote on Nov 10, 2009
I got a better understanding of this issue by reading through this post and this (http://www.iraf.net/phpBB2/viewtopic.php?p=1462787&sid=e74cd735b22f567658feaefe1e542177&sid=e8908484df3b34a1b51f6561a78c3e92) post. The whole thing about byte numbers and multiples is where I figured it out, i didn't realize how much needed to be compatible software wise in order to get some of this stuff to work. Has anybody tried to run Datanumen pst repair, IRAF, and Ubuntu in cohesion?
Last post on Nov 10, 2009