<html dir="ltr">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" id="owaParaStyle"></style>
</head>
<body fpstyle="1" ocsi="0">
<div style="direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;">David,&nbsp;
<div>I retried the exact example, except made the plane a float and that solved it.&nbsp;</div>
<div>thanks for the help,</div>
<div>Matt</div>
<div><br>
<div style="font-family: Times New Roman; color: #000000; font-size: 16px">
<hr tabindex="-1">
<div id="divRpF971194" style="direction: ltr;"><font face="Tahoma" size="2" color="#000000"><b>From:</b> David Jones [jonesd647@yahoo.ca]<br>
<b>Sent:</b> Monday, March 23, 2015 3:40 PM<br>
<b>To:</b> Matthew Fearon; ncl-talk@ucar.edu<br>
<b>Subject:</b> Re: diagonal cross section with wrf_user_intrp3d<br>
</font><br>
</div>
<div></div>
<div>
<div style="color:#000; background-color:#fff; font-family:HelveticaNeue,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; font-size:12px">
<div dir="ltr" id="yui_3_16_0_1_1427149847145_16204"><span>Hi Matt, <br>
</span></div>
<div id="yui_3_16_0_1_1427149847145_17299" dir="ltr"><br>
<span></span></div>
<div id="yui_3_16_0_1_1427149847145_17450" dir="ltr"><span id="yui_3_16_0_1_1427149847145_17449">I may have encountered this problem before. If I recall correctly, wrf_user_intrp3d requires the plane to be floats, rather than integers.</span></div>
<div id="yui_3_16_0_1_1427149847145_17751" dir="ltr"><br>
<span id="yui_3_16_0_1_1427149847145_17449"></span></div>
<div id="yui_3_16_0_1_1427149847145_17752" dir="ltr"><span id="yui_3_16_0_1_1427149847145_17449">You could just change your script to
</span></div>
<div id="yui_3_16_0_1_1427149847145_16205" class="qtdSeparateBR"><br>
<div id="yui_3_16_0_1_1427149847145_17757" dir="ltr">tmp_plane = (/&nbsp; 40,81 , 259,81&nbsp; /)<br class="" style="">
</div>
<div id="yui_3_16_0_1_1427149847145_18063" dir="ltr">plane&nbsp;&nbsp; = tofloat(tmp_plane)<br>
</div>
<div id="yui_3_16_0_1_1427149847145_18068" dir="ltr">&nbsp;tc_plane = wrf_user_intrp3d(tc,z,&quot;v&quot;,plane,0.,True)</div>
<div id="yui_3_16_0_1_1427149847145_18275" dir="ltr"><br>
</div>
<div id="yui_3_16_0_1_1427149847145_18276" dir="ltr">Hope this helps,</div>
<div id="yui_3_16_0_1_1427149847145_18277" dir="ltr">Dave.<br class="" style="">
</div>
<div id="yui_3_16_0_1_1427149847145_18282" class="" dir="ltr" style=""><br class="" style="">
</div>
</div>
<div id="yui_3_16_0_1_1427149847145_16210" class="yahoo_quoted" style="display:block">
<div id="yui_3_16_0_1_1427149847145_16209" style="font-family:HelveticaNeue,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; font-size:12px">
<div id="yui_3_16_0_1_1427149847145_16208" style="font-family:HelveticaNeue,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; font-size:16px">
------------------------------<br>
<div id="yui_3_16_0_1_1427149847145_16217" class="y_msg_container"><br>
Message: 2<br>
Date: Mon, 23 Mar 2015 06:21:51 &#43;0000<br>
From: Matthew Fearon &lt;<a id="yui_3_16_0_1_1427149847145_18067" href="mailto:Matthew.Fearon@dri.edu" target="_blank">Matthew.Fearon@dri.edu</a>&gt;<br>
Subject: [ncl-talk] diagonal cross section with wrf_user_intrp3d<br>
To: &quot;<a id="yui_3_16_0_1_1427149847145_17749" href="mailto:wrf-help@ucar.edu" target="_blank">wrf-help@ucar.edu</a>&quot; &lt;<a id="yui_3_16_0_1_1427149847145_18065" href="mailto:wrf-help@ucar.edu" target="_blank">wrf-help@ucar.edu</a>&gt;, &quot;<a id="yui_3_16_0_1_1427149847145_18066" href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a>&quot;<br>
&nbsp;&nbsp;&nbsp; &lt;<a id="yui_3_16_0_1_1427149847145_18064" href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a>&gt;<br>
Message-ID:<br>
&nbsp;&nbsp;&nbsp; &lt;<a id="yui_3_16_0_1_1427149847145_16531" href="mailto:CE379185CDDDEA4CB6796C413A518A638A2F3AD3@Ex-Reno-MB1.DRI.local" target="_blank">CE379185CDDDEA4CB6796C413A518A638A2F3AD3@Ex-Reno-MB1.DRI.local</a>&gt;<br>
Content-Type: text/plain; charset=&quot;iso-8859-1&quot;<br>
<br>
Dear WRF-help and NCL users,<br>
<br>
Has anyone successfully plotted a cross section with wrf data<br>
along a diagonal, say southeast to northwest or vice versa, using<br>
wrf_user_intrp3d? North/south or east/west works fine, but from the<br>
documentation, a diagonal seemed possible using the example below,<br>
although I can't get it working?<br>
<br>
Also, the plane is defined (/xstart,xend , ystart,yend/) for sure<br>
rather than (/xstart,ystart , xend,yend/) instead?<br>
<br>
thanks,<br>
Matt<br>
<br>
load &quot;$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl&quot;<br>
&nbsp; load &quot;$NCARG_ROOT/lib/ncarg/nclscripts/wrf/WRFUserARW.ncl&quot;<br>
<br>
&nbsp; a = addfile&lt;<a id="yui_3_16_0_1_1427149847145_17291" href="https://www.ncl.ucar.edu/Document/Functions/Built-in/addfile.shtml" target="_blank">https://www.ncl.ucar.edu/Document/Functions/Built-in/addfile.shtml</a>&gt;(&quot;wrfout_d01_2000-01-24_12:00:00.nc&quot;,&quot;r&quot;)<br>
<br>
&nbsp; time = 1<br>
&nbsp; tc = wrf_user_getvar&lt;<a href="https://www.ncl.ucar.edu/Document/Functions/WRF_arw/wrf_user_getvar.shtml" target="_blank">https://www.ncl.ucar.edu/Document/Functions/WRF_arw/wrf_user_getvar.shtml</a>&gt;(a,&quot;tc&quot;,time)&nbsp; ; T [C]<br>
&nbsp; z&nbsp; = wrf_user_getvar&lt;<a id="yui_3_16_0_1_1427149847145_17244" href="https://www.ncl.ucar.edu/Document/Functions/WRF_arw/wrf_user_getvar.shtml" target="_blank">https://www.ncl.ucar.edu/Document/Functions/WRF_arw/wrf_user_getvar.shtml</a>&gt;(a,&quot;z&quot;,time)&nbsp; &nbsp; ;
 z on mass points<br>
<br>
&nbsp; plane = (/&nbsp; 40,81 , 259,81&nbsp; /) ; approx. START x;y and END x;y point<br>
<br>
&nbsp; ; Extract cross section from point A to point B, as defined in &quot;plane&quot;<br>
&nbsp; ; And vertically interpolate to height coordinates (&quot;z&quot;)<br>
&nbsp; tc_plane = wrf_user_intrp3d(tc,z,&quot;v&quot;,plane,0.,True)<br>
-------------- next part --------------<br>
An HTML attachment was scrubbed...<br>
URL: <a id="yui_3_16_0_1_1427149847145_17750" href="http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150323/4b9f2038/attachment-0001.html" target="_blank">
http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150323/4b9f2038/attachment-0001.html
</a><br>
<br>
<br>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>