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

Re: [amibroker] Re: Scanning for stocks not conditions...



PureBytes Links

Trading Reference Links

Have you tried the Cross( ) function to get single occurence
Graham

----- Original Message -----
From: "dtsokakis" <TSOKAKIS@xxxx>
Date: Tuesday, July 16, 2002 7:12 pm
Subject: [amibroker] Re: Scanning for stocks not conditions...

> <html><body>
> 
> 
> <tt>
> Anthony,
> 
> John question is not quite clear for me.
> 
> John wrote:
> 
> &quot;I'm trying to Scan/Explore for stocks whose previous 10 day 
> range is 
> 
> greater than some particular value. This is easy to do in Explore 
> 
> mode but the output consists of multiple occurences of the same 
> 
> stock. 
> 
> Really, I don't want a list of all the occurences of when the 
> 
> stock's range is greater than the value... I REALLY just want the 
> 
> ticker symbol inserted into the list and then the scan should move 
> on 
> 
> to the next symbol.&quot;
> 
> 
> 
> If you explore for n=1 last quotation, you will find stocks with 
> 
> CONDITION=TRUE
> 
> only for the last bar. If for some stock condition was true 5 bars 
> 
> ago, you will miss it.
> 
> This is why I proposed
> 
> 
> 
> COND=...;//your condition here
> 
> x=10;//the days you will search
> 
> Filter=Sum(COND,x)&gt;=1;
> 
> AddColumn(C,&quot;&quot;);
> Set n last quotations n=1 and explore.
> 
> 
> 
> to explore the last x bars and meet the second requirement of one 
> 
> ticker appearence in the result list.
> 
> DT
> 
> --- In amibroker@xxxx, Anthony Faragasso <ajf1111@xxxx&gt; wrote:
> 
> &gt; Dimitri,
> 
> &gt; 
> 
> &gt; Exactly my question... , Without knowing what John wanted to 
> 
> explore, (
> 
> &gt; No formula was posted ) I presumed he was doing a generic 
> explore.
> &gt; 
> 
> &gt; If suppose he is exploring for a condition to be true.Set n last
> 
> &gt; quotations and n=1, click explore.
> 
> &gt; 
> 
> &gt; example:
> 
> &gt; 
> 
> &gt; //Consolidation Breakouts
> 
> &gt; 
> 
> &gt; pds=80;
> 
> &gt; Volpds=60;
> 
> &gt; CongestionIndex=((HHV(C,pds)-LLV(C,pds))/LLV(C,pds))*100;
> 
> &gt; 
> 
> &gt; // Consolidation breakout (upside)
> 
> &gt; 
> 
> &gt; brkup=IIf(Ref(congestionindex,-5)<10 AND IIf(congestionindex 
> &gt;=10 
> 
> AND
> 
> &gt; IIf(Close&gt;Ref(HHV(C,pds),-5) AND
> 
> &gt; IIf(MA(V,5)&gt;=1.5*(Ref(MA(V,Volpds),-5)), 
> 1,0),1,0),1,0),1,0) ;
> 
> &gt; 
> 
> &gt; brkdown=IIf(Ref(congestionindex,-5)<10 AND 
> IIf(congestionindex &gt;=10 
> 
> AND
> 
> &gt; IIf(Close<Ref(LLV(C,pds),-5)AND
> 
> &gt; IIf(MA(V,5)&gt;=1.5*(Ref(MA(V,Volpds),-5)),1,0),1,0),1,0),1,0);
> 
> &gt; 
> 
> &gt; Filter=brkup OR brkdown;
> 
> &gt; 
> 
> &gt; AddColumn(brkup,&quot;Upside&quot;);
> 
> &gt; AddColumn(brkdown,&quot;Downside&quot;);
> 
> &gt; 
> 
> &gt; /**************************************************/
> 
> &gt; 
> 
> &gt; Anthony
> 
> &gt; 
> 
> &gt; dtsokakis wrote:
> 
> &gt; 
> 
> &gt; &gt; John,
> 
> &gt; &gt; What is the exact condition you want to explore ?
> 
> &gt; &gt; DT
> 
> &gt; &gt; --- In amibroker@xxxx, John Nelson <trader@xxxx&gt; wrote:
> 
> &gt; &gt; &gt;
> 
> &gt; &gt; &gt; Right but this has the disadvantage of putting the 
> search range
> 
> &gt; &gt; into the
> 
> &gt; &gt; &gt; program code. Also it doesn't look like you can do 
> this easily 
> 
> for
> 
> &gt; &gt; an
> 
> &gt; &gt; &gt; interval within the price vector... only from the 
> last day back.
> 
> &gt; &gt; Oh
> 
> &gt; &gt; &gt; well, something we just have to live with I guess.
> 
> &gt; &gt; &gt;
> 
> &gt; &gt; &gt; -- John
> 
> &gt; &gt; &gt;
> 
> &gt; &gt; &gt; dtsokakis wrote:
> 
> &gt; &gt; &gt;
> 
> &gt; &gt; &gt; &gt;John,
> 
> &gt; &gt; &gt; &gt;Suppose your want to search a condition COND 
> for the last x 
> 
> days.
> 
> &gt; &gt; &gt; &gt;You may use the exploration
> 
> &gt; &gt; &gt; &gt;
> 
> &gt; &gt; &gt; &gt;COND=C&gt;Ref(C,-1);//your condition here
> 
> &gt; &gt; &gt; &gt;x=10;//the days you will search
> 
> &gt; &gt; &gt; &gt;Filter=Sum(COND,x)&gt;=1;
> 
> &gt; &gt; &gt; &gt;AddColumn(C,&quot;&quot;);
> &gt; &gt; &gt; &gt;
> 
> &gt; &gt; &gt; &gt;Set n last quotations n=1 and explore.
> 
> &gt; &gt; &gt; &gt;You will not see when COND was true, but each 
> ticker will 
> 
> appear
> 
> &gt; &gt; only
> 
> &gt; &gt; &gt; &gt;once in your result list.
> 
> &gt; &gt; &gt; &gt;Dimitris Tsokakis
> 
> &gt; &gt; &gt; &gt;
> 
> &gt; &gt; &gt; &gt;
> 
> &gt; &gt; &gt;
> 
> &gt; &gt; &gt;
> 
> &gt; &gt; &gt; --
> 
> &gt; &gt; &gt; _____________________________________________________
> 
> &gt; &gt; &gt;
> 
> &gt; &gt; &gt; John T. Nelson
> 
> &gt; &gt; &gt; Trader | Dreams Of Empire
> 
> &gt; &gt; &gt; mail: | trader@xxxx
> 
> &gt; &gt; &gt; web: | http://www.dreamsofempire.com/
> 
> &gt; &gt; &gt; _____________________________________________________
> 
> &gt; &gt; &gt; &quot;Prediction is sexy... but strategy makes 
> money&quot;
> &gt; &gt;
> 
> &gt; &gt;
> 
> &gt; &gt; Yahoo! Groups Sponsor
> 
> &gt; [Image]
> 
> &gt; Click here to find your contact lenses!
> 
> &gt; &gt;
> 
> &gt; &gt; Your use of Yahoo! Groups is subject to the Yahoo! Terms 
> of 
> 
> Service.
> 
> 
> 
> </tt>
> 
> 
> 
> 
> <!-- |**|begin egp html banner|**| -->
> 
> <table border=0 cellspacing=0 cellpadding=2>
> <tr bgcolor=#FFFFCC>
> <td align=center><font size="-1" color=#003399><b>Yahoo! Groups 
> Sponsor</b></font></td></tr>
> <tr bgcolor=#FFFFFF>
> <td align=center width=470><table border=0 cellpadding=0 
> cellspacing=0><tr><td align=center><font face=arial size=-
> 2>ADVERTISEMENT</font><img 
> src="http://us.a1.yimg.com/us.yimg.co</td></tr></table></td></tr>
> </table>
> 
> <!-- |**|end egp html banner|**| -->
> 
> 
> 
> 
> 
> <tt>Your use of Yahoo! Groups is subject to the Yahoo! Terms of 
> Service.</tt></br>
> 
> </body></html>
> 
> 

----------------
Powered by telstra.com