<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">#!/bin/csh

set stations = (E1 L4)
#set stations = L4

foreach station($stations) 
   echo $station
   set year = 23 
   while ($year &lt; 25)
      set yy = `printf %02d $year`
      echo $yy
      if (-e CTDf_all_20${yy}_${station}.txt) then 
         /bin/rm CTDf_all_20${yy}_${station}.txt
      endif
      set ss = `echo $station | tr -s '[A-Z]' '[a-z]'`
      cat ../${station}/${yy}????_${ss}.asc &gt;&gt; CTDf_all_20${yy}_${station}.txt    
      tar zcvf ${station}_20${yy}_CTD.tar.gz ../${station}/${yy}????_${ss}.asc
      tar zcvf ${station}_20${yy}_CTD_bottle.tar.gz ../${station}/${yy}????_${ss}.btl
      
      @ year ++
   end
   
end

exit(0)

</pre></body></html>