<div dir="ltr"><div><br></div><div><div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
<span>Variable: index<br>
</span>
<div>Type: integer<br>
</div>Dimensions and sizes: [25] x [1]<span></span><br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
---<br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
new_var = data     [48]</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
new_var = data(index)  ---> How could it work?</div><div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">---</div><div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)"><br></div><div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">Maybe <br></div><div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)"><br></div><div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">new_var = data(index(:,0))</div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Aug 1, 2019 at 9:10 AM Vanúcia Schumacher via ncl-talk <<a href="mailto:ncl-talk@ucar.edu">ncl-talk@ucar.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">




<div dir="ltr">
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
Hi users,</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
I am trying to implement a routine using ind_resolve, and would like to associate another variable by taking the values only in the ranks of these previously calculated indexes. Any ideas on how to do it?<br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
... var [48]</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
index  = ind_resolve(ind(.not.ismissing(var)),dsizes_a) ---> Works</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
ivalid  := ind(.not.ismissing(var))   ; extract only the non-missing values.</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
<span>xvalid  := var(ivalid) </span><br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
<span><br>
</span></div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
<span>Variable: index<br>
</span>
<div>Type: integer<br>
</div>
<div>Total Size: 100 bytes<br>
</div>
<div>            25 values<br>
</div>
<div>Number of Dimensions: 2<br>
</div>
<div>Dimensions and sizes: [25] x [1]<br>
</div>
<div>Coordinates: <br>
</div>
<div>Number Of Attributes: 1<br>
</div>
<div>  _FillValue : -2147483647<br>
</div>
<span></span><br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
new_var = data     [48]</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
new_var = data(index)  ---> How could it work?</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
Thanks</div>
<div style="font-family:Calibri,Helvetica,sans-serif;font-size:14pt;color:rgb(0,0,0)">
<br>
</div>
</div>

_______________________________________________<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/mailman/listinfo/ncl-talk</a></blockquote></div>