There were some wrapping problems in my ET codes. See please http://finance.groups.yahoo.com/group/amibroker/message/69513 for a better response.
This looks a nice & profitable code. Should we use this code only with Index such as ^NDX or it can be used with stocks too. Can we use it in explore to find stocks with red/green arrows? Again, your help is greatly appreciated. Alan
You may use it for stocks too. ^NDX is [for me] indicative for the whole N100 market. As you see in the previous examples, the directionality is quite interesting[higher than 90%]. It would be 100% if we select both the stock and the index to have ascending [or descending] parabolics...
As for the exploration, the parabolic will be ascending [green] when the last zig is a trough and respectively descending [red] when the last zig is a peak. Explore your database for the n=1 last quotations with the fast perc=3; // sensitivity calibration x=BarIndex(); xx=LastValue(x); t1=LastValue(ValueWhen(PeakBars(H,perc) = = 0,x)); t11=LastValue(ValueWhen(TroughBars(L,perc) = = 0,x)); g=t1>t11; Filter=1; AddColumn(g,"",1.0,colorBlack,IIf(g,colorRed,colorGreen));
Thank you for your fast reply. I just wanted to know if it is possible the find stock with the the red/green arrow in the first day it appears on the chart
Well, not exactly the first day. The Peak/Trough investigation is based on zig function and depends on the zig percentage. If, for example, perc=3, a peak will be recognized as a peak as soon as the price falls below the 97% of the peak value. It takes some days as you understand... You may, of course, replace the Zig based Peak condition with another, probably faster but more exposed to whipsaw effects. The most important for the best-fit parabolic method is the quick exit/profit taking. The exit signal occurs BEFORE the upcoming peak/trough, when the first candle is on the right side of the parabola. The exit is premature sometimes, but, it is exactly the profit taking time !! Waiting for more and more profits is catastrophic and I hope you agree...
Please ensure you use the correct code. Example http://finance.groups.yahoo.com/group/amibroker/message/69570