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

[amibroker] Indicator Builder Composite tickers update



PureBytes Links

Trading Reference Links

The question:
To plot in Indicator Builder the population of N100 stocks with MACD()
>Signal() and to update this plot with new EOD.
[3rd party proprietary dlls excluded]
Solution 1: Run in AA the
AddToComposite(MACD()>Signal(),"~MACDBULL","V");
Buy=0;
and have in some IB window the
Plot(100*Foreign("~MACDBULL","V")/101,"MACDBULL",5,8);
It will be automatically updated after the AA scan.
Plus:
The method is very fast and gives a clean result without ambiguous 
points. 
All codes are magically short.
Minus:
The method needs a free AA window, if it is for intraday use and scan 
every 1min to watch the plot changes.
The AA window may be [and should be] occupied to watch the usual 
suspects, these stocks ready to break the bullish condition.
The target of this procedure is to decide a "Buy/Sell at close", half 
an hour [or less] before the end of the session, 
in order to avoid the probable next day dramatic gap up/down.
Solution2:
Necessity is mother of invention:
The IB analytic code
N0="^NDX";C=Foreign(N0,"C");MACD0=MACD();Signal0=Signal
();MACDbull0=MACD0>Signal0;
N1="AAPL";C=Foreign(N1,"C");MACD1=MACD();Signal1=Signal
();MACDbull1=MACD1>Signal1;
N2=...
...
N100="YHOO";C=Foreign(N100,"C");MACD100=MACD();Signal100=Signal
();MACDbull100=MACD100>Signal100;

MACDbull=MACDbull0+MACDbull1+...+MACDbull100;
Plot(100*MACDbull/101,"MACDBULL",5,8);
gives the result of solution1
Minus:
The code is huge [I developed a special technique to write it semi-
automatically in MSEXCEL using the CONCATENCATE function]
and should be changed whenever the N100 changes.
Plus : 
a.The AA window is free for other [useful] explorations.
b.It works.
The request begins from the last Plus b. I need a flexible IB code to 
read internally the database names and give the final MACDBULL
graph without any use of AA window.
I hope it is clear and I believe it is a great AFL step, after the 
irresistible, marvellous AddToComposite() function.
Dimitris Tsokakis





------------------------ Yahoo! Groups Sponsor ---------------------~-->
Rent DVDs from home.
Over 14,500 titles. Free Shipping
& No Late Fees. Try Netflix for FREE!
http://us.click.yahoo.com/BVVfoB/hP.FAA/uetFAA/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 

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