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

[amibroker] Relative strength comparison across a large number of stocks



PureBytes Links

Trading Reference Links

Hey all - I'm interested in trying to do a comparison of stocks, in
terms of relative strength as Tom Dorsey describes it.

Now, for two stocks, this is easy to do.  But what I want to do is
scan a group and then compare them against each other.  So, if have 3
stocks (A,B,C,D), I'd like to compare:

- A and B
- A and C
- A and D
- B and C
- B and D
- C and D (I think I got all the combinations!)

And then I want to rank them and buy the top N stocks.  I'm really not
sure where to begin with this.

I believe I want to use the Rotational backtester - but I'm not clear
on how I would make the positionscore right.  I'm thinking of
something like this (this is pseudo code):

for i = 0 to NumberofEquities - 1
    {
    for j = 0 to NumberofEquities - 1
        {
        Equity(i)_RS = (Equity(i)/Equity(j)) * 1000
        if i > 0 and j > 0 then
            if Equity(i)_RS > Equity(i-1)_RS then
PositionScore(Equity(i)) = PositionScore(Equity(i)) + 1
        }
    }

But I'm really not clear on whether doing something like this is possible.

If anyone could give me a good starting point, I'd appreciated.

Thanks!


------------------------------------

Please note that this group is for discussion between users only.

To get support from AmiBroker please send an e-mail directly to 
SUPPORT {at} amibroker.com

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

For other support material please check also:
http://www.amibroker.com/support.html
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/amibroker/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/amibroker/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:amibroker-digest@xxxxxxxxxxxxxxx 
    mailto:amibroker-fullfeatured@xxxxxxxxxxxxxxx

<*> 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/