<div dir="ltr"><div><div><div><div><div><div><div>Several offline communications later ...<br><br>Ruben provided a nice (small) dataset to test for the 6.4.0 dim_minind function. <br></div>FTR: the 6.4.0 dim_minind works fine.<br><br>==<br></div>The real problem was how to use the returned 2D index index_min(lat,lon).<br></div>Ruben's ultimate objective was to use the returned index values to access a different variable.<br><br></div>Array indexing using an array of indices works differently in different languages. In this case, it is best to use an explicit 'do loop'. <br><br></div>[SNIP]<br>; get 'time index' where the min value occurs<br><br> sst_minind = dim_minind(sst,0) <wbr> ; 6.4.0 <br> printVarSummary(sst_minind)<br> printMinMax(sst_minind,0)<br><br>; use indices to extract values: *must* use explicit 'do'<br></div><div>; Let 'X' be the different variable<br><br> do nl=0,nlat-1<br> do ml=0,mlon-1<br> XMIN(nl,ml) = (/ X(sst_minind(nl,ml),nl,ml) /) ; (/ ... /) avoid warning message<br> end do<br> end do<br><br><br></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Feb 14, 2017 at 11:16 AM, Mary Haley <span dir="ltr"><<a href="mailto:haley@ucar.edu" target="_blank">haley@ucar.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_default" style="font-size:small">I know this was provided offline, but I'll include it here in case anybody else needs it. --M</div><div class="gmail_default" style="font-size:small"><br></div></div><div class="gmail_extra"><br><div class="gmail_quote"><span class="">On Tue, Feb 14, 2017 at 9:23 AM, Ruben van Hooidonk <span dir="ltr"><<a href="mailto:rubski@gmail.com" target="_blank">rubski@gmail.com</a>></span> wrote:<br></span><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr"><div>Hi,<br><br>Does anyone have a workaround for the function "dim_minind" which will become available in the version 6.4.0?<br><br></div><div>Thanks,<br></div><div>Ruben<br></div></div>
<br></div></div><span class="">______________________________<wbr>_________________<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" rel="noreferrer" target="_blank">http://mailman.ucar.edu/mailma<wbr>n/listinfo/ncl-talk</a><br>
<br></span></blockquote></div><br></div>
<br>______________________________<wbr>_________________<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/<wbr>mailman/listinfo/ncl-talk</a><br>
<br></blockquote></div><br></div>