Tim,
> > OK, I've just changed astmapbox so that the LBNDIN and UBNDIN parameters
> > default to the grid bounds of the input NDF. So now you can just do
> >
> > astmapbox $1 \! \! forward=y coordout=3
> >
> > I.e. no need to call ndftrace first.
> >
> > Does this meet your needs?
> >
>
> Seems to work for me (in fact it works for me on files that core dump with
> GETBOUND). I note that GETBOUND presents all the bounds rather than just a
> specified coordinate but that may be a red herring if DATACUBE only ever
> looks at the spectral axis.
GETBOUND presumably calls AST_MAPBOX multiple times, once for each axis.
> It still seems to me that ndftrace could usefully be given the
> functionality to store the wcs bounds (and would be consistent with the
> aims of ndftrace) but it's clearly a lower priority now if 3 calls to
> astmapbox can do the same thing.
Yes - I'll add it to the list but it sounds like it is probably not a high
priority.
> The other outstanding datacube issue is how to obtain the units of the
> spectral axis. What's the recommended way to get the axis units from a
> file? [transparently such that the units can come from the current frame
> so that SpecFrames and AXIS will work].
Units is just like all other attributes - you can get it, set it, test
it, or clear it using kappa:wcsattrib. Fot instance, if the spectral axis
is axis 2, you can do:
% wcsattrib fred get "unit(2)"
David
|