Welcome to iraf.net Saturday, April 20 2024 @ 07:50 AM GMT


 Forum Index > Help Desk > Applications New Topic Post Reply
 sigma spectra in spectool
   
Anonymous: Guest
 10/11/2005 03:46PM (Read 5234 times)  



On Tue, 04 Oct 2005 17:16:00 -0700 Achim wrote:> Hi Phillip,
>
> I am using SPECTOOL to fit Gaussian line profiles and would like to
> use the error estimation function. However, I have difficulties
> assigning a sigma spectrum to the data using the spectrum
> arithmetic tool.
>
> I tried just to assign a constant sigma, just for testing, i.e.
> highlighted the sigma radio button, entered a value, put output
> register to current, hit return, but no sigma spectrum appears (I
> enabled that in the View control panel), and no fitting errors are
> displayed. Ultimately, I would like to use a file in another register
> as the sigma.
>
> Is that a bug? I know it should work, since I have used it a long
> time ago in a previous version successfully. I suppose that there is
> no easy way to produce a IRAF/spectool readable file from ascii that
> has the sigma already associated.
>
> I would appreciate if you could check the assigning of a sigma
> spectrum via the spectrum arithmetics on your linux machine. I use
> the SuSE spectool binaries that you sent me a while ago on SuSE
> 9.2.
>
Hi Achim,I think what you are trying to do is what is done by the tasks in
apextract. If you want to add a sigma spectrum to your spectrum, then
the following information may prove useful (this information was from a
reply to another user by another IRAF support person). The example
provided makes use of the artdata package to add what you want to a
spectrum.As far as I can tell, spectool will not add a sigma spectrum. The
spectrum arithmetic tool will only modify what already exists.I hope that helps. Let us know if you have further questions or
problems.Cheers,Phillip------------------------------------------------------------------------mkpattern temp ndim=3 ncols=3680 nlines=1 n3=2 header=testspec
imcopy testspec[*,2,1] temp[*,1,1]
imcopy testspec[*,2,2] temp[*,1,2]
hedit temp wat0_001 "system=equispec" add+ verify-
hedit temp apnum1 "1 1" add+ verify-
scopy temp test format=multispec
imdel temp
spectool test plotsig+The first command is from the ARTDATA package and it creates an empty
3680x1x2 image. The next two commands copy the spectrum and the sigmas
into the first and second planes. The next command adds a keyword that
identifies the format as "equispec" which IRAF and SPECTOOL uses.
The APNUM1 keyword is needed to associate an aperture number with the
particular line. If there are multiple spectra then there would need
to be one
for each line. Note that aperture information need not be the same
as the line
numbers.At this point the format is close and some tasks will be happy but
not SPECTOOL.
So we use SCOPY to formally produce all the keywords associated with the
equispec and multispec formats.Note that in the registers you should only see one thing. The
associated spectra
are not considered separate registers. The "control panel" is where
you can
set which things to plot....the header from the final:on> imhead test
test[3680,1,2][real]:
No bad pixels, min=0., max=0. (old)
Line storage mode, physdim [3680,1,2], length of user area 1175 s.u.
Created Fri 11:48:05 15-Jul-2005, Last modified Fri 11:48:05 15-Jul-2005
Pixel file "test.fits" [ok]
EXTEND = T / File may contain extensions
ORIGIN = 'NOAO-IRAF FITS Image Kernel July 2003' / FITS file originator
DATE = '2005-07-15T18:48:05' / Date FITS file was generated
IRAF-TLM= '11:48:05 (15/07/2005)' / Time of last modification
WCSDIM = 3
DC-FLAG = 1 / Log-linear flag
BUNIT = '1.0E-17 erg/cm/s/Ang' / units
COEFF0 = 3.59106000000000E+00 / Center wavelength (log10) of first pi
COEFF1 = 1.00000000000000E-04 / Log10 dispersion per pixel
CRVAL1 = 3.59116 / Iraf zero point
CD1_1 = 1.00000000000000E-04 / Iraf dispersion
WAT0_001= 'system=equispec'
APNUM1 = '1 1 '
BANDID1 = 'spectrum'
BANDID2 = 'sigma '
CTYPE1 = 'LINEAR '
CTYPE2 = 'LINEAR '
CTYPE3 = 'LINEAR '
CRPIX1 = 1.
CD2_2 = 1.
CD3_3 = 1.
LTM1_1 = 1.
LTM2_2 = 1.
LTM3_3 = 1.
WAT1_001= 'wtype=linear units=Angstroms'
WAT2_001= 'wtype=linear'
WAT3_001= 'wtype=linear'

 
 Quote
Anonymous: Guest
 10/11/2005 03:46PM  



On Tue, 04 Oct 2005 17:16:00 -0700 Achim wrote:> Hi Phillip,
>
> I am using SPECTOOL to fit Gaussian line profiles and would like to
> use the error estimation function. However, I have difficulties
> assigning a sigma spectrum to the data using the spectrum
> arithmetic tool.
>
> I tried just to assign a constant sigma, just for testing, i.e.
> highlighted the sigma radio button, entered a value, put output
> register to current, hit return, but no sigma spectrum appears (I
> enabled that in the View control panel), and no fitting errors are
> displayed. Ultimately, I would like to use a file in another register
> as the sigma.
>
> Is that a bug? I know it should work, since I have used it a long
> time ago in a previous version successfully. I suppose that there is
> no easy way to produce a IRAF/spectool readable file from ascii that
> has the sigma already associated.
>
> I would appreciate if you could check the assigning of a sigma
> spectrum via the spectrum arithmetics on your linux machine. I use
> the SuSE spectool binaries that you sent me a while ago on SuSE
> 9.2.Hi again, Achim,There is some further information from the reply, that may prove
useful, that discusses the multispec format.I hope that helps.Cheers,Phillip
----------------------------------------------------------------------The format is automatically produced when the IRAF aperture extraction
tasks are run with parameters to output the "extras" spectra and the
information needed to compute uncertainties during extraction are
specified.So let me tell you what the format is and some hints on how you can
create it. 1D spectra in IRAF are currently lines in the first plane
of 1D, 2D, or 3D images; in section notation these
are [*], [*,?], or [*,?,1] where ? is some line number. When there
are multiple lines these are multiple spectra. The associated
spectra are specified in 3D images. The planes are
sometimes called "bands" which is why the keywords you need are
BANDIDn, where n
is the coordinate along the 3rd dimension.So you need to make a IxJxK image. J may be 1 for a single spectrum
with associated information. Then you need to create the keywords
BANDIDk where the values are "spectrum", "raw", "sky", "sigma", or
"continuum". Only the first word is used so something like "sigma
based on a model" is as good as "sigma".The tasks which you might use for this (in addition to any others
that you know that generate FITS files) are IMSTACK and HEDIT. As a
hint, you can use IMSTACK with just one file to increase the
dimensionality:cl> imstack spec1d spec2d
cl> imstack sigma1d sigma2d
cl> imstack spec2d,sigma2d spec3d
cl> hedit spec3d bandid2 sigma add+
cl> imhead spec3d l+
[...]
BANDID2 = 'sigma'
[...]

 
 Quote
   
Content generated in: 0.02 seconds
New Topic Post Reply

Normal Topic Normal Topic
Sticky Topic Sticky Topic
Locked Topic Locked Topic
New Post New Post
Sticky Topic W/ New Post Sticky Topic W/ New Post
Locked Topic W/ New Post Locked Topic W/ New Post
View Anonymous Posts 
Anonymous users can post 
Filtered HTML Allowed 
Censored Content 
dog allergies remedies cialis 20 mg chilblain remedies


Privacy Policy
Terms of Use

User Functions

Login