[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[amibroker] Re: Second time around - a question and a possible bug. Tomasz??



PureBytes Links

Trading Reference Links




<SPAN 
class=987011917-23062004>How about something like this 
(untested):
<SPAN 
class=987011917-23062004> 
<SPAN 
class=987011917-23062004>Sell = IIf(BarsSince(Cond1B) < BarsSince(Cond2B), 
Cond1S, Cond2S);
<SPAN 
class=987011917-23062004> 
<SPAN 
class=987011917-23062004>Dave Merrill
<BLOCKQUOTE 
>
  I want to combine two systems I have into one 
  BackTest.
   
  The first is to buy if Cond1B is true and sell if Cond1S is 
  true.
   
  The second is to buy if Cond2B is true and sell if Cond2S is 
  true.
   
  Now, I want to buy if either are true:
   
  Buy = Cond1B OR Cond1S;
   
  Then, if I bought because of Cond1B, I only want to test for 
  Cond1S for selling, and if I bought because of Cond2B, then I only want to 
  test Cond1S.
   
  How can I accomplish this?
   
  <FONT 
size=2>Linda


Check AmiBroker web page at:
http://www.amibroker.com/

Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html








Yahoo! Groups Sponsor


  ADVERTISEMENT 












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:amibroker-unsubscribe@xxxxxxxxxxxxxxx 
Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.