Welcome to iraf.net Tuesday, May 21 2024 @ 02:08 AM GMT


 Forum Index > Help Desk > General IRAF New Topic Post Reply
 running a task in multiple directories?
   
Arp
 10/19/2009 12:03PM (Read 1685 times)  
++---
Junior

Status: offline


Registered: 06/15/2009
Posts: 34
Hi!I've got about several hundred fits files, and I'd like to extract a specific value from their headers. But those files are in different folders, so I tried hedit -r ... but that does not work. Is there a way I can tell iraf, or in this case hedit to look in all (sub)directories and analyse all fits files?(and how can I put those results into a text file?)
Thx.

 
Profile Email
 Quote
fitz
 10/19/2009 12:03PM  
AAAAA
Admin

Status: offline


Registered: 09/30/2005
Posts: 4040
The FILES or SECTIONS tasks you would normally use to create lists of images don't support descending subdirectories (although that would be an interesting new feature to add). Instead you can create the file list using the host 'find' command, e.g.[code:1:6939cf244d]
cl> find . -name \*.fits -print > flist
cl> hedit @flist foo yes
[/code:1:6939cf244d]The 'find' task is declared as foreign in your login.cl and so doesn't need to be escaped. Also, are you sure you didn't mean you wanted to use the HSELECT task to get the value, or by 'extract' do you mean delete?-Mike

 
Profile Email
 Quote
Arp
 10/19/2009 12:03PM  
++---
Junior

Status: offline


Registered: 06/15/2009
Posts: 34
Hi!Thank you.Im not sure what HSELECT does, but I read that HEDIT can be used to to show the values of specific header fields. Thats all I want to do, read the value of a specific field, in this case the GAIN Value of around 2000 files in around 400 directories Smile

 
Profile Email
 Quote
   
Content generated in: 0.16 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