Thanks for the tip! I'll look into that, it seems much more straight forward.
Don't worry, I'll ask for help if I get stuck! :) Thanks! Carla --- In amibroker@yahoogroups.com, "Edward Pottasch" <[EMAIL PROTECTED]> wrote: > > hi, > > you can do it like that but in Amibroker you can also work with arrays. So for instance: > > constraint1 = .......; > constraint2 = .......; > > constraint1 and 2 are both arrays that contain "0" and "1". > > allconstraints = constraint1 AND constraint2; > > now allconstraints is an array that carries the values 0 when only 1 or neither constraint applies and it carries 1 when both constraints apply, > > So then: > > Buy = allconstraints; > > rgds, Ed > > > > > ----- Original Message ----- > From: carlacash26 > To: amibroker@yahoogroups.com > Sent: Thursday, October 12, 2006 1:40 PM > Subject: [amibroker] Nested if-statements > > > Hi! > > I have a system that has a few indicators. I want to code this in > amibroker. > > I want a buy signal when all of the indicators acts in a specific way. > > When one of my indicators acts the way i like a variabel is set > to "true" (or 1), when all of these are true, i want the buy signal. > > So when a,b,c, or d are == 1 then give buy signal. > Is this done like this with nested if-statements? > > if (a == 1){ > if (b == 1){ > if (c == 1){ > if (d == 1){ > > BUY-SIGNAL > > } > } > } > } > > Thanks! > 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/ <*> Your email settings: Individual Email | Traditional <*> To change settings online go to: http://groups.yahoo.com/group/amibroker/join (Yahoo! ID required) <*> To change settings via email: mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] <*> 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/