Hello Ferreters,
I encountered a bizarre problem when doing regridding within a repeat command. The following is a reproducible example to illustrate the problem.
can data/a
use "http://iridl.ldeo.columbia.edu/SOURCES/.NOAA/.NODC/.WOA01/.Grid-1x1/.Annual/.an/.temperature/dods"
use "http://iridl.ldeo.columbia.edu/SOURCES/.NOAA/.NODC/.WOA01/.Grid-5x5/.Annual/.mn/.temperature/dods"
use etopo20repeat/range=1:2/name=m \
(let mask = if rose[d=etopo20,gxy=temperature[d=`m`]@nrst] le 0 then 1; \ shade/k=1 temperature[d=`m`]*mask; \
pause; \
can var mask; \
can view; \
)What this script essentially does is to mask out all the land grid points in the original data (it of course makes little sense here since the original data are already ocean-only, but my working wind stress data do have valid values over both lands and oceans). But if you execute the above script, you will find the masking in the second plot gets messed up. What's not intelligible to me is that if I mask the second data alone, the resultant plot appears simply all right. This is on Ferret v6.1 32-bit Linux version.
Did I miss anything obvious? Thanks!
David