<div dir="ltr">Hi Zhuxiao,<div><div>To access the contents of a list, you need to refer to the index position of the list enclosed by [ ]. Thus, to get at the 2nd list in the PV array try this: </div><div>theta = PV[1]</div><div>Adam</div><div><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Apr 10, 2018 at 3:36 PM, Zhuxiao Li - NOAA Affiliate <span dir="ltr"><<a href="mailto:zhuxiao.li@noaa.gov" target="_blank">zhuxiao.li@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 dir="ltr">Hi Dennis and Adam,<div><br></div><div>Excuse me for the late response. My time today has been fully scheduled until just now, I had a try with Dennis attachment and Adam's debug suggestion, the good news is both the issue a) and b) has been resolved!  For issue b) I think the code revise worked! As for issue a), after I apply the debug idea of Adam, I realized the it is my careless fault to get lat by 'lat=f[:]->lat' instead of 'lat=f[0]->lat'. so the size of the lat is the multiple of the real lat!  thanks very much for the very helpful guide from you both, I also learned how to debug on NCL code and my own code!</div><div><br></div><div>Now here is the simple question, if I set opt=1, I got a list variable e.g. PV,  how to quote (or express) the variables (s, theta, pv),  I mean 'theta=PV(1, :, :, :, :)' ?</div><div><br></div><div>Cheers,</div><div>Zhuxiao</div><div><br></div><div> </div></div></blockquote></div><div><br></div>-- <br><div class="m_3877775731913368317m_-3942845868234205410m_2436884670539950076gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div><div><span><font color="#888888">Adam Phillips <br></font></span></div><span><font color="#888888">Associate Scientist,  </font></span><span><font color="#888888">Climate and Global Dynamics Laboratory, NCAR<br></font></span></div></div><div><span><font color="#888888"><a href="http://www.cgd.ucar.edu/staff/asphilli/" target="_blank">www.cgd.ucar.edu/staff/asphill<wbr>i/</a>   </font></span><span><font color="#888888">303-497-1726 </font></span></div><span><font color="#888888"></font></span><div><div><span><font color="#888888"><br></font></span><div><span><font color="#888888"><a href="http://www.cgd.ucar.edu/staff/asphilli" target="_blank"></a></font></span></div></div></div></div></div></div></div></div></div></div></div>
</div></div></div>