<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=us-ascii" http-equiv=Content-Type>
<META name=GENERATOR content="MSHTML 8.00.6001.18939"></HEAD>
<BODY
style="WORD-WRAP: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space">
<DIV dir=ltr align=left><SPAN class=005345409-27102010><FONT color=#0000ff
size=2 face=Arial>oops! (Will Smith flying an alien space ship in Indepenance
Day)</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=005345409-27102010><FONT color=#0000ff
size=2 face=Arial></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=005345409-27102010><FONT color=#0000ff
size=2 face=Arial>Thanks!<BR>Bernd.</FONT></SPAN></DIV>
<DIV> </DIV><!-- Converted from text/plain format -->
<P><FONT size=2>--<BR>Bernd Becker Climate Impacts Product
Development<BR>Met Office Hadley Centre FitzRoy Road
Exeter Devon EX1 3PB United Kingdom<BR>Tel.: +44 (0) 1392
884511 Fax: +44 (0)870 900 5050<BR>E-mail:bernd.becker@metoffice.gov.uk - <A
href="http://www.metoffice.gov.uk/research/our-scientists/seasonal-to-decadal/bernd-becker">http://www.metoffice.gov.uk/research/our-scientists/seasonal-to-decadal/bernd-becker</A><BR><BR></FONT></P>
<DIV> </DIV><BR>
<DIV dir=ltr lang=en-us class=OutlookMessageHeader align=left>
<HR tabIndex=-1>
<FONT size=2 face=Tahoma><B>From:</B> gradsusr-bounces@gradsusr.org
[mailto:gradsusr-bounces@gradsusr.org] <B>On Behalf Of </B>Jennifer
Adams<BR><B>Sent:</B> 26 October 2010 17:06<BR><B>To:</B> GrADS Users
Forum<BR><B>Subject:</B> Re: [gradsusr] if test in grads script going
awol<BR></FONT><BR></DIV>
<DIV></DIV>Bernd,
<DIV>Get rid of the 'then' in your 'if' statement -- it is not part of the 'if'
clause syntax. </DIV>
<DIV>--Jennifer</DIV>
<DIV><BR>
<DIV>
<DIV>On Oct 26, 2010, at 10:06 AM, Becker, Bernd wrote:</DIV><BR
class=Apple-interchange-newline>
<BLOCKQUOTE type="cite">
<DIV><BR>dear all, <BR>what is wrong with
this?<BR><BR><BR>ignore=(20101021)<BR><BR>in=0<BR>while ( in < 1
)<BR> in= in +1<BR><BR>* check current date against
list of dates to be ignored:<BR> dimfx
= subwrd(ignore, in)<BR> say
rc' 'valnum(dimfx)<BR> dimfx =
math_format('%10.2f', dimfx )<BR> ifxdate
= math_format('%10.2f', fxdate
)<BR> skip=(ifxdate-dimfx)/1.<BR>* this is zero to trigger
skip<BR> say rc' 'dimfx' 'ifxdate' 'skip
' 'valnum(skip)
<BR> if ( skip = int(0)
)
then<BR> say 'skip 'dimfx
'
'fxdate<BR> else<BR> say 'not
skip 'dimfx
'
'fxdate<BR><BR><BR>for the life of it, skip is always true! even if skip is
anything but<BR>zero!<BR><BR>What can I do to skip if skip
=0?<BR><BR>Cheers,<BR>Bernd.<BR><BR>--<BR>Bernd Becker Climate
Impacts Product Development<BR>Met Office Hadley Centre
FitzRoy Road Exeter Devon EX1 3PB
United<BR>Kingdom<BR>Tel.: +44 (0) 1392 884511 Fax: +44 (0)870 900
5050<BR>E-mail:<A
href="mailto:bernd.becker@metoffice.gov.uk">bernd.becker@metoffice.gov.uk</A>
-<BR><A
href="http://www.metoffice.gov.uk/research/our-scientists/seasonal-to-decadal/">http://www.metoffice.gov.uk/research/our-scientists/seasonal-to-decadal/</A><BR>bernd-becker<BR><BR><BR>_______________________________________________<BR>gradsusr
mailing
list<BR>gradsusr@gradsusr.org<BR>http://gradsusr.org/mailman/listinfo/gradsusr<BR></DIV></BLOCKQUOTE></DIV><BR>
<DIV apple-content-edited="true"><SPAN
style="WIDOWS: 2; TEXT-TRANSFORM: none; TEXT-INDENT: 0px; BORDER-SPACING: 0px 0px; BORDER-COLLAPSE: separate; FONT: 12px Helvetica; WHITE-SPACE: normal; ORPHANS: 2; LETTER-SPACING: normal; COLOR: rgb(0,0,0); WORD-SPACING: 0px; -khtml-text-decorations-in-effect: none; -apple-text-size-adjust: auto"
class=Apple-style-span>
<DIV
style="WORD-WRAP: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space"><SPAN
style="WIDOWS: 2; TEXT-TRANSFORM: none; TEXT-INDENT: 0px; BORDER-SPACING: 0px 0px; BORDER-COLLAPSE: separate; FONT: 12px Helvetica; WHITE-SPACE: normal; ORPHANS: 2; LETTER-SPACING: normal; COLOR: rgb(0,0,0); WORD-SPACING: 0px; -khtml-text-decorations-in-effect: none; -apple-text-size-adjust: auto"
class=Apple-style-span><SPAN
style="WIDOWS: 2; TEXT-TRANSFORM: none; TEXT-INDENT: 0px; BORDER-SPACING: 0px 0px; BORDER-COLLAPSE: separate; FONT: 12px Helvetica; WHITE-SPACE: normal; ORPHANS: 2; LETTER-SPACING: normal; COLOR: rgb(0,0,0); WORD-SPACING: 0px; -khtml-text-decorations-in-effect: none; -apple-text-size-adjust: auto"
class=Apple-style-span>
<DIV>--</DIV>
<DIV>Jennifer M. Adams</DIV>
<DIV>IGES/COLA</DIV>
<DIV>4041 Powder Mill Road, Suite 302</DIV>
<DIV>Calverton, MD 20705</DIV>
<DIV><A href="mailto:jma@cola.iges.org">jma@cola.iges.org</A></DIV>
<DIV><BR class=khtml-block-placeholder></DIV><BR
class=Apple-interchange-newline></SPAN></SPAN></DIV></SPAN></DIV><BR></DIV></BODY></HTML>