<div dir="ltr"><div><div><div>Hi Matt,<br><br></div>I don&#39;t know definitively, but my reading of the docs on dim_pqsort suggest, along with its attendant example #2, suggest that it does indeed do what you want.  You could cobble together a small test case to verify.<br><br></div>HTH...<br></div>Rick<br><br><div><div><div><br><br></div></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Aug 26, 2015 at 2:32 PM, Matthew Fearon <span dir="ltr">&lt;<a href="mailto:Matthew.Fearon@dri.edu" target="_blank">Matthew.Fearon@dri.edu</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">




<div>
<div style="direction:ltr;font-family:Tahoma;color:#000000;font-size:10pt">
<div>Does dim_pqsort do this?</div>
<div><br>
</div>
In my example, if I did  x = dim_pqsort(precip, -2) , is x the indices of the sorted array (descending) that I could apply to the other variables to order them consistent with precip? 
<div><br>
</div>
<div>thanks for the help.<br>
<div><br>
<div style="font-family:Times New Roman;color:#000000;font-size:16px">
<hr>
<div style="direction:ltr"><font color="#000000" face="Tahoma" size="2"><b>From:</b> <a href="mailto:ncl-talk-bounces@ucar.edu" target="_blank">ncl-talk-bounces@ucar.edu</a> [<a href="mailto:ncl-talk-bounces@ucar.edu" target="_blank">ncl-talk-bounces@ucar.edu</a>] on behalf of Matthew Fearon [<a href="mailto:Matthew.Fearon@dri.edu" target="_blank">Matthew.Fearon@dri.edu</a>]<br>
<b>Sent:</b> Wednesday, August 26, 2015 1:20 PM<br>
<b>To:</b> <a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a><br>
<b>Subject:</b> [ncl-talk] sort multiple 1D vectors with a common timestamp according to one, without a loop<br>
</font><br>
</div><div><div class="h5">
<div></div>
<div>
<div style="direction:ltr;font-family:Tahoma;color:#000000;font-size:10pt">Dear NCL users,
<div><br>
</div>
<div>Trying to sort multiple 1D vectors according to one primary vector. For example, I have temp, rh, wind, and precip as 1D vectors of the same length, and they corresponding in time. How can I sort precip descending and attached the corresponding temp, rh,
 and wind to it, without a loop? </div>
<div><br>
</div>
<div>thanks,</div>
<div>Matt</div>
<div><br>
</div>
</div>
</div>
</div></div></div>
</div>
</div>
</div>
</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>