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

Re: [amibroker] Re: Re: empty scan of a watchlist (?)



PureBytes Links

Trading Reference Links




Tomasz,
It seems we speak different languages, or you use another 
piece of software !!
I created a WL20 with ^NDX, AAPL and AMZN, deleted the last 5 
AAPL quotations , scan for WL20 the 

AddToComposite(1<FONT 
size=2>,"~count",<FONT 
size=2>"V");Buy=0<FONT 
size=2>;
and then pasted in IB y o u r  c o d 
e
//Count tickers in watchlist function 
//For Indicator Builder 
WatchlistNumber=Param(<FONT 
size=2>"Watchlist",20<FONT 
size=2>,0,<FONT 
size=2>63,1) 
;//enter watchlist number 
function CountTickersInWatchList( Listnum ) 
{ 
// retrive comma-separated list of symbols in watch list 

list = GetCategorySymbols( 
categoryWatchlist, listnum ); 
Counter=0; // 
INITIALIZE COUNTER 
for( i = <FONT 
size=2>0; ( sym = StrExtract<FONT 
size=2>( list, i ) ) != ""; i++ ) 
{ 
// TO COUNT BAR BY BAR YOU HAVE TO USE ARRAYS NOT SCALAR 
AND USE FOREIGN TO FIND OUT HOLES
Counter=Counter + ( NOT IsNull( 
Foreign( sym, <FONT 
size=2>"C", False ) ) ); 
} 
return Counter; 
} Title="Watchlist # "+<FONT 
size=2>WriteVal(watchlistnumber,<FONT 
size=2>1)+" has "+ 

CountTickersInWatchList( WatchlistNumber) + " 
Tickers"; 
Plot(CountTickersInWatchList( WatchlistNumber) 
,"",1<FONT 
size=2>,1); 
Plot(Foreign<FONT 
size=2>("~count",<FONT 
size=2>"v"),""<FONT 
size=2>,4,<FONT 
size=2>2); 
The result is in the att. gif.
This is my amibroker 4.50.6 graph.[My base index is ^NDX]
Dimitris Tsokakis 
 


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 the Yahoo! Terms of Service.







Attachment:
1t.gif

Attachment: Description: "Description: GIF image"