<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; color: rgb(0, 0, 0); font-size: 14px; font-family: Calibri, sans-serif;">
<div>
<div>Thank you Stephen! I’ll give those a shot.</div>
<div><br>
</div>
<div>Best,</div>
<div>Sam</div>
<div><br>
</div>
</div>
<div><br>
</div>
<span id="OLK_SRC_BODY_SECTION">
<div style="font-family:Calibri; font-size:11pt; text-align:left; color:black; BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; PADDING-BOTTOM: 0in; PADDING-LEFT: 0in; PADDING-RIGHT: 0in; BORDER-TOP: #b5c4df 1pt solid; BORDER-RIGHT: medium none; PADDING-TOP: 3pt">
<span style="font-weight:bold">From: </span><<a href="mailto:gradsusr-bounces@gradsusr.org">gradsusr-bounces@gradsusr.org</a>> on behalf of Stephen McMillan <<a href="mailto:smcmillan@planalytics.com">smcmillan@planalytics.com</a>><br>
<span style="font-weight:bold">Reply-To: </span>GrADS Users Forum <<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a>><br>
<span style="font-weight:bold">Date: </span>Thursday, June 23, 2016 at 2:13 PM<br>
<span style="font-weight:bold">To: </span>GrADS Users Forum <<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a>><br>
<span style="font-weight:bold">Subject: </span>Re: [gradsusr] Find nearest valid data<br>
</div>
<div><br>
</div>
<div>
<div>
<div dir="ltr">Hi Sam,
<div><br>
</div>
<div>'set x 1';'set y 1'</div>
<div>'set gxout print';'set prnopts %0.3f' or your format of choice</div>
<div>'d gr2stn(var,lon,lat,-n)' where var is the variable you wish to query</div>
<div><br>
</div>
<div>-n gets value from nearest grid to that lon/lat</div>
<div><br>
</div>
<div>You could also use 'q defval...' to query specific grids surrounding a point, using the x and y coordinates. References:</div>
<div><br>
</div>
<div><a href="http://cola.gmu.edu/grads/gadoc/gradfuncgr2stn.html">http://cola.gmu.edu/grads/gadoc/gradfuncgr2stn.html</a><br>
</div>
<div><br>
</div>
<div><a href="http://cola.gmu.edu/grads/gadoc/gradcomdquery.html">http://cola.gmu.edu/grads/gadoc/gradcomdquery.html</a><br>
</div>
<div><br>
</div>
<div>You might find 'set gxout grid' useful in displaying the grid values surrounding a point</div>
<div><br>
</div>
<div>Stephen</div>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On Thu, Jun 23, 2016 at 4:55 PM, Sam Wilson <span dir="ltr">
<<a href="mailto:sam@surfline.com" target="_blank">sam@surfline.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word;color:rgb(0,0,0)">
<div><font face="Calibri">Hi,</font></div>
<div><font face="Calibri"><br>
</font></div>
<div><font face="Calibri">I came across the following issue and am having the same problem but never saw a response:</font></div>
<div><font face="Calibri"><br>
</font></div>
<div><font face="Calibri"><a href="http://gradsusr.org/pipermail/gradsusr/2010-July/028033.html" target="_blank"></a><a href="http://gradsusr.org/pipermail/gradsusr/2010-July/028033.html" target="_blank"></a></font>
<p class="MsoNormal"><b><font face="Calibri" size="3"><a href="http://gradsusr.org/pipermail/gradsusr/2010-July/028033.html" target="_blank">http://gradsusr.org/pipermail/gradsusr/2010-July/028033.html</a><u></u><u></u></font></b></p>
<p class="MsoNormal"><b><font face="Calibri" size="3"><br>
</font></b></p>
<p class="MsoNormal"><font face="Calibri" size="3">I know by default GrADS will return data from the nearest grid point to the lat/lon specified. Is there any sort of function that will return the nearest non-undefined data?</font></p>
<p class="MsoNormal"><font face="Calibri" size="3"><br>
</font></p>
<p class="MsoNormal"><font face="Calibri" size="3">Thanks,</font></p>
<p class="MsoNormal"><font face="Calibri" size="3">Sam </font></p>
</div>
<div><br>
</div>
</div>
<br>
_______________________________________________<br>
gradsusr mailing list<br>
<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>
<a href="http://gradsusr.org/mailman/listinfo/gradsusr" rel="noreferrer" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><br>
<br>
</blockquote>
</div>
<br>
</div>
</div>
</div>
</span>
</body>
</html>