<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Thanks Jeff, <o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>I should have mentioned, initially I tried running zinterp from a script, but once that wasn&#8217;t working I was trying to trouble shoot on the command line.&nbsp; I tried your suggestion and put</span><span style='font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1F497D'> </span><span style='font-size:10.0pt'>'zinterp(tmpprs,hgtprs,5000)' <span style='color:#1F497D'>as the first line in the zinterp.gs script, I then tried running a very short script that just opened a ctl file and &#8216;d zinterp(tmpprs,hgtprs,5000)&#8217;<o:p></o:p></span></span></p><p class=MsoNormal><span style='font-size:10.0pt;color:#1F497D'>I again get the following error: <o:p></o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt'>Syntax Error:&nbsp; Invalid Operand <o:p></o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt'>&nbsp;&nbsp;'zinterp' not a variable or function name<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt'>&nbsp; Error ocurred at column 1<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt'>DISPLAY error:&nbsp; Invalid expression <o:p></o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt'>&nbsp;&nbsp;Expression = zinterp(tmprs,hgtprs,5000)<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>I also tried putting &#8216;zinterp(tmpprs,hgtprs,5000)&#8217; on the second line of zinterp.gs (under function zinterp(field,zgrid,zlev)) and got the same error.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Not sure what I&#8217;m missing.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Thanks for the help,<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Meredith<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> gradsusr-bounces@gradsusr.org [mailto:gradsusr-bounces@gradsusr.org] <b>On Behalf Of </b>Jeffrey Duda<br><b>Sent:</b> Thursday, April 21, 2011 3:45 PM<br><b>To:</b> GrADS Users Forum<br><b>Subject:</b> Re: [gradsusr] zinterp.gs<o:p></o:p></span></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal style='margin-bottom:12.0pt'>Meredith,<br>To my knowledge, you can't run a function from the Grads command prompt.&nbsp; Instead, you need to put in a call to it inside a script that contains the function code.&nbsp; Thus, just put the line 'zinterp(tmpprs,hgtprs,5000)' as the first line of code in the <a href="http://zinterp.gs">zinterp.gs</a> script file.<br><br>Jeff Duda<o:p></o:p></p><div><p class=MsoNormal>On Thu, Apr 21, 2011 at 2:02 PM, Meredith Croke &lt;<a href="mailto:mcroke@airdat.com">mcroke@airdat.com</a>&gt; wrote:<o:p></o:p></p><p class=MsoNormal style='margin-bottom:12.0pt'>Hi Grads Users,<br><br><br><br>I'm trying to use the <a href="http://zinterp.gs" target="_blank">zinterp.gs</a> function to determine the 6km wind from<br>model data that is output on pressure levels, however I'm running into<br>some issues with <a href="http://zinterp.gs" target="_blank">zinterp.gs</a>.<br><br><br><br>To test the function I am attempting to run it from the command line and<br>follow the samples in the script, so I have tried<br><br>'d zinterp(tmpprs,hgtprs,5000)', to display a temperature field at 5000,<br>however I receive this error:<br><br>Syntax Error: &nbsp;Invalid Operand<br><br>&nbsp;'zinterp' not a variable or function name<br><br>&nbsp;Error ocurred at column 1<br><br>DISPLAY error: &nbsp;Invalid expression<br><br>&nbsp;Expression = zinterp(tmpprs,hgtprs,5000)<br><br><br><br>The function is in my directory, &nbsp;what else do I need to do to get this<br>to work?<br><br>I am using grads v1.9b4<br><br><br><br>Thanks for your help.<br><br><br><br>Regards,<br><span style='color:#888888'><br><br><br>Meredith<br><br><br><br></span><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" target="_blank">http://gradsusr.org/mailman/listinfo/gradsusr</a><o:p></o:p></p></div><p class=MsoNormal><br><br clear=all><br>-- <br>Jeff Duda<br>Iowa State University<br>Meteorology Graduate Student<br>3134 Agronomy Hall<br><a href="http://www.meteor.iastate.edu/~jdduda">www.meteor.iastate.edu/~jdduda</a><o:p></o:p></p></div></body></html>