[ncl-talk] Fix topography contour in animation

Sebastian Otarola-Bustos Sebastian.F.Otarola-Bustos.1 at nd.edu
Tue Jul 21 04:40:47 MDT 2015


Hi All,

I'm trying to do an animation of different fields and I need to plot also
topography contours, because I'm working in a valley surrounded by
mountains. I'm doing something like this:

   do n=0,ntimes-1
      wks = gsn_open_wks("png","animate"+sprinti("%03i",n))
      print("Trabajando en el tiempo: " + times(n))
      res at gsnRightString  = "    Tiempo:  "+ times(n)
      res at gsnDraw = False
      res at gsnFrame = False
      plotB = gsn_csm_contour(wks,SLP(n,:,:),res)
      plotA = gsn_csm_contour(wks,ter(:,:),ter_res)

      map = gsn_csm_map(wks,map_res)
       overlay(map,plotB)
      overlay(map,plotA)
      draw(map)
      frame(wks)

      delete(wks)   ; Make sure PNG file is closed
    end do

The problem is, as I'm creating the workstation inside de loop, I have to
plot topography(which is a static field) every time. And when I finally see
the animation, the contours are fixed, but the contour numbers are moving
all the time. Does anybody know other way to the the same or to fix this?


All the best,
Sebastián.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150721/4976a0b1/attachment.html 


More information about the ncl-talk mailing list