#!/bin/csh

  set modelruns = (dms_ndg1_ctl2_tirf dms_ndg2_ctl2_tirf dms_ndg3_ctl2_tirf dms_ndg4_ctl2_tirf dms_ndg5_ctl2_tirf \
                   dms_ndg1_ctl1_tirf dms_ndg2_ctl1_tirf dms_ndg3_ctl1_tirf dms_ndg4_ctl1_tirf dms_ndg5_ctl1_tirf)
  set indir     = /raid/rc40/data/ANTHRO/dms/

 foreach n ( `seq ${#modelruns}` )
   if ($n <= 5) then
       set trange = "1999m01_2001m12"
   else
       set trange = "2049m01_2051m12"
   endif

#  set ii    = 1
#  set nmon  = 12
#  set tmp   = 9
  set runid=$modelruns[$n]
  echo .................................................
  echo                working on runid   =  $runid
  echo                run number         =  $n
  echo .................................................
     ccc2nc -notxt ${indir}pa_${runid}_${trange}_m09_gp.001
     ccc2nc -notxt ${indir}pa_${runid}_${trange}_ann_gp.001
     ccc2nc -notxt ${indir}pa_${runid}_${trange}_djf_gp.001
     ccc2nc -notxt ${indir}pa_${runid}_${trange}_mam_gp.001
     ccc2nc -notxt ${indir}pa_${runid}_${trange}_jja_gp.001
     ccc2nc -notxt ${indir}pa_${runid}_${trange}_son_gp.001


#  while ($ii <= $nmon)
#    if ($ii <= $tmp) then
#       set mn = 0${ii}
#     else
#      set mn = ${ii}
#   endif
#     ccc2nc -notxt ${indir}pa_anthro_${runid}_2008m01_2012m12_m${mn}_gp.001

#  @ ii ++
# end
end
