Hi, Are colorGreen and colorWhite boolean variables? If so, I think you can simply do:
Buy = ExRem( EntrySignal, ExitSignal ) AND (colorGreen OR colorWhite) intermilan04 --- In [email protected], "Bargains Club" <[EMAIL PROTECTED]> wrote: > > I want BUY = (when color is GREEN or WHITE), how do I code it please? > > > > Here are my code.. > > > > //******************************************************* > > // #4 VOLATILITY Ribbon CODES > > //******************************************************* > > EntrySignal = C > ( LLV( L, 10 ) + 2 * ATR( 10 ) ); > > ExitSignal = C < ( HHV( H, 10 ) - 2 * ATR( 10 ) ); > > Color = IIf( EntrySignal, colorGreen, IIf( ExitSignal, colorRed, colorWhite > )); > > TrailStop = HHV( C - 2 * ATR(10), 15 ); > > ProfitTaker = EMA( H, 13 ) + 2 * ATR(10); > > > > Buy = ExRem( EntrySignal, ExitSignal ) AND (COLOR IS GREEN OR WHITE); > > SELL = ExRem( eXITsIGNAL, eNTRYsIGNAL ); > > > > Thanks for your help. > Please note that this group is for discussion between users only. To get support from AmiBroker please send an e-mail directly to SUPPORT {at} amibroker.com For other support material please check also: http://www.amibroker.com/support.html Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/amibroker/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/
