<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
</head>
<body>
<div name="messageBodySection" style="font-size: 14px; font-family: -apple-system, BlinkMacSystemFont, sans-serif;">Hi Mary,
<div><br /></div>
<div>Thanks for the clarification. I was not aware of the example you mentioned.&#160;</div>
<div>Still doing the regridding level by level is a good idea.</div>
</div>
<div name="messageSignatureSection" style="font-size: 14px; font-family: -apple-system, BlinkMacSystemFont, sans-serif;"><br />
/M<br />
<br />
Marston S. Johnston, PhD<br />
Department of Earth Sciences<br />
University of Gothenburg, Sweden<br />
Email: marston.johnston@gu.se<br />
SkypeID: marston.johnston<br />
Phone: +46-31-7864901<br />
Only the fruitful thing is true!</div>
<div name="messageReplySection" style="font-size: 14px; font-family: -apple-system, BlinkMacSystemFont, sans-serif;"><br />
On 31 Mar 2017, 21:53 +0200, Mary Haley &lt;haley@ucar.edu&gt;, wrote:<br />
<blockquote type="cite" style="margin: 5px 5px; padding-left: 10px; border-left: thin solid #1abc9c;">
<div dir="ltr">
<div class="gmail_default" style="font-size:small">Amanda and Marston,</div>
<div class="gmail_default" style="font-size:small"><br /></div>
<div class="gmail_default" style="font-size:small">If you are simply talking about regridding each level independently, then you can actually pass a 3D variable to ESMF_regrid, and it will do the looping under the hood. What this function does is creates the weights for one level, and applies them to the rest of the levels.&#160; It assumes that the lat/lon grid is the same for each level.</div>
<div class="gmail_default" style="font-size:small"><br /></div>
<div class="gmail_default" style="font-size:small">If the lat/lon grid changes for each level, or you have different locations for missing values for each level, then yes, you need to loop and do the regridding separately for each level.</div>
<div class="gmail_default" style="font-size:small"><br /></div>
<div class="gmail_default" style="font-size:small">Examples ESMF_regrid_5.ncl does this, although it's not very well advertised. You just pass in the 3D variable instead of a 2D variable, and it should work.</div>
<div class="gmail_default" style="font-size:small"><br /></div>
<div class="gmail_default" style="font-size:small">--Mary</div>
</div>
<div class="gmail_extra"><br />
<div class="gmail_quote">On Fri, Mar 31, 2017 at 5:07 AM, Marston Johnston <span dir="ltr">&lt;<a href="mailto:shejo284@gmail.com" target="_blank">shejo284@gmail.com</a>&gt;</span> wrote:<br />
<blockquote class="gmail_quote" style="margin: 5px 5px; padding-left: 10px; border-left: thin solid #e67e22;">
<div>
<div name="messageBodySection" style="font-size:14px;font-family:-apple-system,BlinkMacSystemFont,sans-serif">You have to loop over the depth yourself. Even if ESMF would do this for you - and it doesn’t, it would still just do a 2D regrid inside a loop over the depth.&#160;</div>
<div name="messageReplySection" style="font-size:14px;font-family:-apple-system,BlinkMacSystemFont,sans-serif">
<div>
<div class="h5"><br />
On 31 Mar 2017, 12:55 +0200, Amanda Frigola &lt;<a href="mailto:afrigola@marum.de" target="_blank">afrigola@marum.de</a>&gt;, wrote:<br /></div>
</div>
<blockquote type="cite" style="margin: 5px 5px; padding-left: 10px; border-left: thin solid #3498db;">
<div>
<div class="h5">Hi there!
<div><br />
<div style="font-size:13px">I am trying to regrid a 3D variable with coordinates (depth, lat_1, lon_1) to â€‹coordinates (depth, lat_2, lon_2).&#160;</div>
<div style="font-size:13px">I wanted to use the function ESMF_regrid for that, but I can only find examples for 2D variables online.&#160;</div>
<div style="font-size:13px">My version of ncl is 6.3.0.&#160;</div>
<div style="font-size:13px">Any clue about how to get there?</div>
</div>
<div style="font-size:13px"><br /></div>
<div style="font-size:13px">Amanda</div>
</div>
</div>
______________________________<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" target="_blank">http://mailman.ucar.edu/<wbr />mailman/listinfo/ncl-talk</a><br /></blockquote>
</div>
</div>
<br />
______________________________<wbr />_________________<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/<wbr />mailman/listinfo/ncl-talk</a><br />
<br /></blockquote>
</div>
<br /></div>
</blockquote>
</div>
</body>
</html>