<div dir="ltr">Excellent suggestion. When you send questions to ncl-talk, it is suggested that you *always* include a printVarSummary(...) of your variable(s). How are people supposed to know the variable structure. You know (hopefully) but ncl-talk does not! Note: it is also suggested that you include the NCL version you are using.<div><br></div><div>Since you are concerned with meta data, you should do a before and after printVarSummary(...).</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jun 24, 2015 at 11:15 AM, Walter Kolczynski <span dir="ltr"><<a href="mailto:walter.kolczynski@noaa.gov" target="_blank">walter.kolczynski@noaa.gov</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
Have you tried a <tt>printVarSummary </tt>to see what your
metadata actually is, both before and after <tt>where</tt>?<br>
<br>
- Walter<div><div class="h5"><br>
<br>
<div>On 24-Jun-15 12:18, Erik J.
Schaffernicht wrote:<br>
</div>
<blockquote type="cite">Now,
I rewrote my ncl-script because on first sight it seemed you are
right. But when it comes to gsn_csm_contour_map (or somewhere
else, there is no line number given with the warning messages)
<br>
I get these warnings:
<br>
<br>
(0) check_for_y_lat_coord: Warning: Data either does not
contain a valid latitude coordinate array or doesn't contain one
at all.
<br>
(0) A valid latitude coordinate array should have a 'units'
attribute equal to one of the following values:
<br>
(0) 'degrees_north' 'degrees-north' 'degree_north' 'degrees
north' 'degrees_N' 'Degrees_north' 'degree_N' 'degreeN' 'degreesN'
'deg north'
<br>
<br>
and the only thing I changed was this:
<br>
<br>
w2=sediProbab
<br>
w2=where(landAreaFrV .lt. 0.5, w2@_FillValue, w2)
<br>
copy_VarMeta(sediProbab,w2)
<br>
sediProbab=w2
<br>
<br>
to
<br>
<br>
sediProbab=where(landAreaFrV .lt. 0.5, sediProbab@_FillValue,
sediProbab)
<br>
<br>
<br>
So, what is happening there with the where()
<br>
<br>
<br>
<br>
<br>
<br>
On 23.06.2015 14:58, Carl Schreck wrote:
<br>
<blockquote type="cite">You should be able to simply do:
<br>
<br>
sediProbab = where(landAreaFrV .lt. 0.5, sediProbab@_FillValue,
sediProbab)
<br>
<br>
sediProbab's metadata will be unchanged.
<br>
<br>
Carl
<br>
<br>
On Tue, Jun 23, 2015 at 7:14 AM, Erik J. Schaffernicht <
<br>
<a href="mailto:eschaffe@uni-koeln.de" target="_blank">eschaffe@uni-koeln.de</a>> wrote:
<br>
<br>
<blockquote type="cite">Is there an easier/shorter way(?) than
the following to keep the metaData:
<br>
<br>
(sediProbab is a matrix with
metaData)
<br>
<br>
w2=sediProbab
<br>
w2=where(landAreaFrV .lt. 0.5, w2@_FillValue, w2)
<br>
copy_VarMeta(sediProbab,w2)
<br>
sediProbab=w2
<br>
<br>
<br>
<br>
_______________________________________________
<br>
ncl-talk mailing list
<br>
<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a>
<br>
List instructions, subscriber options, unsubscribe:
<br>
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" target="_blank">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a>
<br>
<br>
<br>
</blockquote>
<br>
</blockquote>
<br>
<br>
<br>
<fieldset></fieldset>
<br>
<pre>_______________________________________________
ncl-talk mailing list
<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a>
List instructions, subscriber options, unsubscribe:
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" target="_blank">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a>
</pre>
</blockquote>
<br>
</div></div><span class="HOEnZb"><font color="#888888"><pre cols="72">--
Walter Kolczynski, Jr.
Global Ensemble Team
NOAA/NWS/NCEP/EMC (via I.M. Systems Group)
<a href="tel:%28301%29%20683-3781" value="+13016833781" target="_blank">(301) 683-3781</a></pre>
</font></span></div>
<br>_______________________________________________<br>
ncl-talk mailing list<br>
<a href="mailto:ncl-talk@ucar.edu">ncl-talk@ucar.edu</a><br>
List instructions, subscriber options, unsubscribe:<br>
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" rel="noreferrer" target="_blank">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a><br>
<br></blockquote></div><br></div>