PureBytes Links
Trading Reference Links
|
Hello,
a solution ( if I understand you) would be to rank Tickers in a
Watchlist on a monthly basis, and use this monthly rank on daily
signal.
Filtering your buy signal with
Buy= something and Rank<101 // top 100
example below with MFI
list = GetCategorySymbols( categoryWatchlist, 0 );
TimeFrameSet( inMonthly );
StockNb=0;
for( i = 0; ( sym = StrExtract( list, i ) ) != ""; i++ )
{
SetForeign(sym);
VarSet("MyInd"+i,MFI(14));// Indicator
StockNb++;
RestorePriceArrays();
}
Rank=1;
for(i=0;i<stockNb;i++)
{
Rank=Rank + IIf(MFI(14)< VarGet("MyInd"+i),1,0);
}
TimeFrameRestore();
Plot(TimeFrameExpand( rank, inMonthly ),"",2,1);
>
> Hi Tomasz,
>
> > Of course it is possible to implement it in AFL.
> > What is impossible is to write a code for every user on every
> request.
>
> I suppose my request looked like it was directed at you but I
thought
> anyone on the forum could reply. Thanks.
>
> Anyway, I'll give up on the idea unless there is easier way (any
> gurus?) because ranking them monthly to find the top *** ONE
HUNDRED
> ONLY *** would need to:
>
> 1. Run this in AA for each month:
>
> TimeFrameSet( inMonthly );
> PositionScore = C * V;
> TimeFrameRestore();
> PositionScore = TimeFrameExpand( PositionScore, inMonthly );
>
> 2. Export the results to Excel.
> 3. Find the turnover for the 100th stock
> 4. Add the value to a chart (Top100)
> 5. AA backtester add a filter (C * V) >= foreign(Top100).
>
> Regards Rangaroopa
>
>
> --- In amibroker@xxxxxxxxxxxxxxx, "Tomasz Janeczko"
<amibroker@xxxx>
> wrote:
> > Hello,
> >
> > Of course it is possible to implement it in AFL.
> >
> > What is impossible is to write a code for every user on every
> request.
> >
> > As to:
> > >> ie: if I run a scan with the timeframe on monthly with C * V
and
> > > rank
> > >> the highest to lowest, I would like the highest 100. Doing
this
> for
> > >> every month for backtesting.
> >
> > It is easy with time frame functions. It takes 4 lines of code.
> >
> > TimeFrameSet( inMonthly );
> > PositionScore = C * V;
> > TimeFrameRestore();
> >
> > PositionScore = TimeFrameExpand( PositionScore, inMonthly );
> >
> > Once you feed AmiBroker with correct score for each security, it
> will rank
> > them for you automatically.
> >
> > Best regards,
> > Tomasz Janeczko
> > amibroker.com
> > ----- Original Message -----
> > From: "rangaroopa2000" <rangaroopa2000@xxxx>
> > To: <amibroker@xxxxxxxxxxxxxxx>
> > Sent: Thursday, December 16, 2004 9:29 PM
> > Subject: [amibroker] Re: Top 100 Backtest
> >
> >
> > >
> > >
> > > Hi,
> > >
> > > I guess this (Top 100) is not possible with the latest
functions
> in
> > > Amibroker then?
> > >
> > > Regards
> > >
> > > --- In amibroker@xxxxxxxxxxxxxxx, "rangaroopa2000"
> > > <rangaroopa2000@xxxx> wrote:
> > >>
> > >> Hello Tomasz,
> > >>
> > >> Thankyou for your reply.
> > >>
> > >> Maybe I wasn't too clear with my words but what you suggest
and
> > > from
> > >> my understanding, I would be able to backtest only
the "latest"
> top
> > >> 100.
> > >>
> > >> I would like to find the top 100 for each and every month in
the
> > > past
> > >> five years or so. They would vary as would the actual top 100
> stock
> > >> do.
> > >>
> > >> ie: if I run a scan with the timeframe on monthly with C * V
and
> > > rank
> > >> the highest to lowest, I would like the highest 100. Doing
this
> for
> > >> every month for backtesting.
> > >>
> > >> Thanks again.
> > >>
> > >>
> > >>
> > >>
> > >>
> > >> --- In amibroker@xxxxxxxxxxxxxxx, "Tomasz Janeczko"
> > > <amibroker@xxxx>
> > >> wrote:
> > >> > Hello,
> > >> >
> > >> > It is easy, run an exploration with average volume:
> > >> >
> > >> > Filter = BarIndex() == BarCount - 1;
> > >> > AddColumn( MA( V, 100 ), "Avg volume" );
> > >> >
> > >> >
> > >> > Then click on "Avg. volume" output column to sort it.
> > >> > Then select top N (say top 100) from the list and
> > >> > click with right mouse button over the list and
> > >> > choose "Add selected results to watch list".
> > >> >
> > >> > From then on top-100 stocks will be on watch list of your
> > >> > choice and you will be able to backtest them.
> > >> >
> > >> > You can also do this directly from backtest formula
> > >> > (without need to run exploration).
> > >> > Just use
> > >> >
> > >> > PositionScore = MA( V, 100 );
> > >> >
> > >> > and backtester will automatically prefer stocks with higher
> > > average
> > >> volume.
> > >> >
> > >> > Best regards,
> > >> > Tomasz Janeczko
> > >> > amibroker.com
> > >> > ----- Original Message -----
> > >> > From: "rangaroopa2000" <rangaroopa2000@xxxx>
> > >> > To: <amibroker@xxxxxxxxxxxxxxx>
> > >> > Sent: Tuesday, December 14, 2004 10:46 AM
> > >> > Subject: [amibroker] Re: Top 100 Backtest
> > >> >
> > >> >
> > >> > >
> > >> > >
> > >> > > Hi Ron,
> > >> > >
> > >> > > Thanks for replying.
> > >> > >
> > >> > > It's difficult if not impossible to find a list of the top
> 100
> > >> stocks
> > >> > > over the past 5 years or so and I think using turnover
would
> be
> > >> good
> > >> > > anyway.
> > >> > >
> > >> > > I suppose I could go through each month and export the
> turnover
> > >> and
> > >> > > pick out the top 100 and create a chart of the results. I
> just
> > >> thought
> > >> > > there maybe an easy way with all the fantastic functions
AB
> has
> > >> now!
> > >> > >
> > >> > > BTW sorry about the double post.
> > >> > >
> > >> > > Regards
> > >> > >
> > >> > > --- In amibroker@xxxxxxxxxxxxxxx, "mrdavis9"
<mrdavis9@xxxx>
> > >> wrote:
> > >> > >> There was some coding done here on this board very
recently
> In
> > >> > > (November??) regarding Float turnover.
> > >> > >>
> > >> > >> Steve Woods wrote a book about Float turnover as well.
> > >> > >>
> > >> > >> One of the posters (Herman ) on this board was involved in
> > >> > > developing the recently developed code, and I think (but
am
> not
> > >> sure)
> > >> > > that someone also developed a way to retrieve the float
> amounts
> > >> from
> > >> > > Yahoo. Hope this helps. Ron D
> > >> > >>
> > >> > >> ----- Original Message -----
> > >> > >> From: rangaroopa2000
> > >> > >> To: amibroker@xxxxxxxxxxxxxxx
> > >> > >> Sent: Monday, December 13, 2004 8:10 PM
> > >> > >> Subject: [amibroker] Top 100 Backtest
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >> Hi,
> > >> > >>
> > >> > >> I would like to trade top 100 stocks and to backtest
> these
> > >> stocks
> > >> > >> with a MONTHLY timeframe using turnover.
> > >> > >>
> > >> > >> Is there an easy way to find these please per month.
> > >> > >>
> > >> > >> Regards Rangaroopa
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >> Check AmiBroker web page at:
> > >> > >> http://www.amibroker.com/
> > >> > >>
> > >> > >> Check group FAQ at:
> > >> > >
http://groups.yahoo.com/group/amibroker/files/groupfaq.html
> > >> > >> Yahoo! Groups Links
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >>
> > >> > >> ---
> > >> > >> Outgoing mail is certified Virus Free.
> > >> > >> Checked by AVG anti-virus system
(http://www.grisoft.com).
> > >> > >> Version: 6.0.809 / Virus Database: 551 - Release Date:
> > >> 12/10/2004
> > >> > >
> > >> > >
> > >> > >
> > >> > >
> > >> > >
> > >> > >
> > >> > > Check AmiBroker web page at:
> > >> > > http://www.amibroker.com/
> > >> > >
> > >> > > Check group FAQ at:
> > >> http://groups.yahoo.com/group/amibroker/files/groupfaq.html
> > >> > > Yahoo! Groups Links
> > >> > >
> > >> > >
> > >> > >
> > >> > >
> > >> > >
> > >> > >
> > >> > >
> > >> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > > Check AmiBroker web page at:
> > > http://www.amibroker.com/
> > >
> > > Check group FAQ at:
> http://groups.yahoo.com/group/amibroker/files/groupfaq.html
> > > Yahoo! Groups Links
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
------------------------ Yahoo! Groups Sponsor --------------------~-->
$4.98 domain names from Yahoo!. Register anything.
http://us.click.yahoo.com/Q7_YsB/neXJAA/yQLSAA/GHeqlB/TM
--------------------------------------------------------------------~->
Check AmiBroker web page at:
http://www.amibroker.com/
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/
|