Hi Mary,<div> I put the "pt_miao.nc"(just one month data) in the "incoming" folder , because I cannot see the list of this folder ,I'm not sure if I succeed .So I attached it , you can download for testing.</div><div>Hope this helps.</div><div>Miao</div><div><br><br><blockquote name="replyContent" class="ReferenceQuote" style="padding-left:5px;margin-left:5px;border-left:#b6b6b6 2px solid;margin-right:0">-----原始邮件-----<br>
<b>发件人:</b><span id="rc_from">"Mary Haley" <haley@ucar.edu></span><br>
<b>发送时间:</b><span id="rc_senttime">2017-06-02 05:16:12 (星期五)</span><br>
<b>收件人:</b> "王淼" <miaowang2015@pku.edu.cn><br>
<b>抄送:</b> "ncl-talk@ucar.edu" <ncl-talk@ucar.edu><br>
<b>主题:</b> Re: [ncl-talk] Problem of using "get_isolines"<br><br><div dir="ltr"><div class="gmail_default" style="font-size:small">Hi,</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">We were looking into this problem using a different example, and seeing some odd results.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">Is it possible for you to provide us with the <a href="http://pt.nc" target="_blank">pt.nc</a> file?</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">You can use our ftp, if the file is not too large:</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default"><a href="http://www.ncl.ucar.edu/report_bug.shtml#HowToFTP" target="_blank">http://www.ncl.ucar.edu/report_bug.shtml#HowToFTP</a><br></div><div class="gmail_default"><br></div><div class="gmail_default">Thanks,</div><div class="gmail_default"><br></div><div class="gmail_default">--Mary</div><div class="gmail_default"><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, May 30, 2017 at 8:17 PM, 王淼 <span dir="ltr"><<a href="mailto:miaowang2015@pku.edu.cn" target="_blank">miaowang2015@pku.edu.cn</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><font style="background-color:rgb(255,255,255)" size="3" face="Courier">Hi Ncl Talk,</font><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> I used get_isolines to get<span style="color:rgb(51,51,51)"> the points that define a contour line .When I printed the longitude of these points , the distribution of the longitude wasn't the same(gonna show in the following example) ,may be [0~-360] or [20~-340],etc. I have expected the function may return the longitude as [0~360] or [-180~180]. I googled it ,but didn't help.I still don't know what caused the effect, so I ask you for help. Thanks!</span></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"><br></font></div><div><font color="#333333" style="background-color:rgb(255,255,255)" size="3" face="Courier">Here is the code and resluts:</font></div><div><font color="#333333"><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"><br></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier">load "$NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/gsn_code.ncl"</wbr></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier">load "$NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/gsn_csm.ncl"</wbr></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier">load "$NCARG_ROOT/lib/ncarg/<wbr>nclscripts/csm/contributed.<wbr>ncl"</wbr></wbr></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier">load "$NCARG_ROOT/lib/ncarg/<wbr>nclscripts/contrib/cd_string.<wbr>ncl"</wbr></wbr></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"><br></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier">begin</font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"><br></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier">f1=addfile("<a href="http://pt.nc" target="_blank">pt.nc</a>","r") ;pt(time,lat,lon)</font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier">pt=short2flt(f1->pt) </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier">pt=lonFlip(pt) ;lon=0~360degrees </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"><br></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier">n=dimsizes(pt&time)</font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"><br></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"><br></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> wks = gsn_open_wks("pdf","sypt_all") </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> res = True </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> res@gsnDraw = False</font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> res@gsnFrame = False</font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"><br></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> res@cnFillOn = False </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> res@cnLinesOn = True </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"><br></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> res@cnLevelSelectionMode = "ExplicitLevels" </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> res@cnLevels = (/350,360/) </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"><br></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> res@mpMinLatF = 0 </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> res@mpCenterLonF =180 </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier">res@trGridType = "TriangularMesh" </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"><br></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"><br></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier">do i = 0, n-1 ;time</font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> plot=gsn_csm_contour_map_ce(<wbr>wks, pt(i,:,:), res) </wbr></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> isolines = get_isolines(plot@contour,"<wbr>plot") </wbr></font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> do j= 0, ListCount(isolines) - 1</font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> iso := isolines[j] </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> idx=maxind(iso@n_points)</font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> b = iso@start_point(idx) </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> e = b + iso@n_points(idx) - 1 </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> y := iso(0,b:e) </font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> x := iso(1,b:e) ;y=lat,x=lon</font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> print(x)</font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier"> end do</font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier">end do</font></div><div><font style="background-color:rgb(255,255,255)" size="3" face="Courier">end </font></div><div style="font-family:verdana,sans-serif;font-size:13.3333px"><br></div><div style="font-family:verdana,sans-serif;font-size:13.3333px"><table border="0" cellpadding="0" cellspacing="0" width="144" style="border-collapse:collapse;width:108pt"> <colgroup><col width="72" span="2" style="width:54pt"> </colgroup><tbody><tr height="19" style="height:14.25pt"> <td height="19" width="72" style="height:14.25pt;width:54pt">result1</td> <td width="72" style="width:54pt">result2</td> </tr> <tr height="19" style="height:14.25pt"> <td height="19" align="right" style="height:14.25pt">0</td> <td class="m_-6371595060249658642xl65" align="right" width="72" style="width:54pt">0</td> </tr> <tr height="19" style="height:14.25pt"> <td height="19" align="right" style="height:14.25pt">-1.8</td> <td class="m_-6371595060249658642xl65" align="right" width="72" style="width:54pt">-1.3</td> </tr> <tr height="19" style="height:14.25pt"> <td height="19" align="right" style="height:14.25pt">-2.5</td> <td class="m_-6371595060249658642xl65" align="right" width="72" style="width:54pt">-2.5</td> </tr> <tr height="19" style="height:14.25pt"> <td height="19" style="height:14.25pt"> …</td> <td class="m_-6371595060249658642xl65" width="72" style="width:54pt"> …</td> </tr> <tr height="19" style="height:14.25pt"> <td height="19" align="right" style="height:14.25pt">-358.9</td> <td class="m_-6371595060249658642xl65" align="right" width="72" style="width:54pt">-339.8</td> </tr> <tr height="19" style="height:14.25pt"> <td height="19" align="right" style="height:14.25pt">-359.7</td> <td class="m_-6371595060249658642xl65" align="right" width="72" style="width:54pt">-340</td> </tr> <tr height="19" style="height:14.25pt"> <td height="19" align="right" style="height:14.25pt">-360</td> <td class="m_-6371595060249658642xl65" width="72" style="width:54pt"> …</td> </tr> <tr height="19" style="height:14.25pt"> <td height="19" style="height:14.25pt"></td> <td class="m_-6371595060249658642xl65" align="right" width="72" style="width:54pt">20</td> </tr> <tr height="19" style="height:14.25pt"> <td height="19" style="height:14.25pt"></td> <td class="m_-6371595060249658642xl65" align="right" width="72" style="width:54pt">18.6</td> </tr> <tr height="19" style="height:14.25pt"> <td height="19" style="height:14.25pt"></td> <td class="m_-6371595060249658642xl65" width="72" style="width:54pt"> …</td> </tr> <tr height="19" style="height:14.25pt"> <td height="19" style="height:14.25pt"></td> <td class="m_-6371595060249658642xl65" align="right" width="72" style="width:54pt">2.5</td> </tr> <tr height="19" style="height:14.25pt"> <td height="19" style="height:14.25pt"></td> <td class="m_-6371595060249658642xl65" align="right" width="72" style="width:54pt">0.5</td> </tr> <tr height="19" style="height:14.25pt"> <td height="19" style="height:14.25pt"></td> <td class="m_-6371595060249658642xl65" align="right" width="72" style="width:54pt">0</td> </tr></tbody></table><br></div></font></div><br><br><span><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</wbr></a></span><br>______________________________<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/<wbr>mailman/listinfo/ncl-talk</wbr></a><br>
<br></wbr></blockquote></div><br></div>
</blockquote></div>