View on GitHub

IRAF Community Distribution

IRAF maintained by the community

Home | Installation | Packages | X11IRAF | PyRAF | Forum

Quick IRAF question (regarding task tprint)

Guest wrote on Oct 17, 2006

Hello IRAFers!

I haven't been able to figure out the answer to my question either from documentation or speaking with some of my colleagues here - was hoping you could help!

this deals with task TPRINT and related - while technically an STSDAS task, I think my question has more to do with the CL...

for some reason I cannot specify a list of output files to TPRINT

if I cd to a directory containing many iraf tables, for example,  I do the following:

ls *.tab -1 > input.list
cp input.list output.list
#edit output.list to replace ".tab" with ".dat" (my output filenames)

then, in iraf

tprint @input.list > @output.list

does not make the individual .dat files, it only makes 1 file called "@output.list" with every single table printed to it!

normally this is not the behavior of the CL as it should have read the list of filenames in output.list (because I used the "@"), correct?

do you have an idea of what I'm doing wrong? if not, not worries!

-Grant in Baltimore

--
_____________________________________
Grant R. Tremblay | Science Division
Space Telescope Science Institute
3700 San Martin Drive, Baltimore, MD 21218
grant@stsci.edu ([email]grant@stsci.edu[/email]) | 410-338-4594
www.stsci.edu/~grant
_____________________________________
Post generated using Mail2Forum (http://www.mail2forum.com)

Mike Fitzpatrick wrote on Oct 17, 2006

The use of @files only works as you're expecting in the case where there is an output (list) parameter for the task. In the case of TPRINT there can be multiple input files but the '>' will redirect ALL output from the command (as it would in unix). If you want to split the output you'll need to process each input file in turn in some sort of loop.

Cheers,
-Mike

Last post on Oct 17, 2006