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

[amibroker] Re: AFL Syntax Question #2 (New)



PureBytes Links

Trading Reference Links

Ronbo, DT had a response for another query similar to this using the sum
formula

MultiBuy = sum(buy,3)>0;
MultiSell = sum(sell,3)>0;

Cheers,
Graham
http://e-wire.net.au/~eb_kavan/

-----Original Message-----
From: ronbo [mailto:ronbo@xxxxxxxxxxxxxx] 
Sent: Monday, May 03, 2004 10:35 AM
To: Amibroker
Subject: [amibroker] How else can i do this---CategoryAddSymbol

I am using EOD and at the end is my code.

i am trying to get the Buys and Sells (B&S) which get printed in the Scan or
Exploration (S&E) to be added to the appropriate WatchList (WL).  Only the
very last signal is written to the WL, but both the B&S are listed in the
S&E results.

When i choose an ending date, that dates signal gets written to the WL, but
with a Range of 3 days, only the last day results get written.

Usually what i want is a Range of 1 day, and the signals get written to the
WL just fine.  But there are days where i want, say, the last 3 days of
signals for all the stock i track.  IOW, i want all signals which have
occurred in the last 3 days.

How do i do this without having to change the Range Date, From, 3 times?

thanks,
ron


Buy=Cross( MACD(), Signal() );
Sell = Cross( Signal(), MACD() );

Filter=Buy OR Sell;
AddColumn (Buy, "test");

if (SelectedValue(Buy) == 1)
{
CategoryAddSymbol("", categoryWatchlist, 0);
}

if (SelectedValue(Sell) == 1)
{
CategoryAddSymbol("", categoryWatchlist, 1);

}
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.667 / Virus Database: 429 - Release Date: 4/23/2004




Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at:
http://groups.yahoo.com/group/amibroker/files/groupfaq.html 
Yahoo! Groups Links



 



------------------------ Yahoo! Groups Sponsor ---------------------~-->
Buy Ink Cartridges or Refill Kits for your HP, Epson, Canon or Lexmark
Printer at MyInks.com.  Free s/h on orders $50 or more to the US & Canada.
http://www.c1tracking.com/l.asp?cid=5511
http://us.click.yahoo.com/mOAaAA/3exGAA/qnsNAA/GHeqlB/TM
---------------------------------------------------------------------~->

Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.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:
     amibroker-unsubscribe@xxxxxxxxxxxxxxx

<*> Your use of Yahoo! Groups is subject to:
     http://docs.yahoo.com/info/terms/