Rank: Newbie
Groups: Registered, Registered Users Joined: 3/19/2010(UTC) Posts: 5
|
Dear colleagues
I would like to compare a stock's indicator value X (AAPL) with all the other stock's indicator values X (MSFT, MRK and so on) in a specific folder and then create a "Ranking Indicator".
The goal is to plot the daily value of the "Ranking Indicator" in the price plot window of all the individual stocks.
As an example:
DAY1: ---- Stock A Day 1 Indicator Value X = 10
Stock B Day 1 Indicator Value X = 5
Stock C Day 1 Indicator Value X = 1
Ranking indicator value: ------------------------ On Day 1 Stock A has a higher indicator value than stock B and stock C, so stock A would get 3 points. On Day 1 Stock B has a higher indicator value than stock C, so stock B would get 2 points.
On Day 1 Stock C has the lowest indicator value, so stock A would get 1 point.
DAY2: ---- Stock A Day 2 Indicator Value 1
Stock B Day 2 Indicator Value 5
Stock C Day 2 Indicator Value 10
Ranking indicator value: ------------------------
On Day 2 Stock A has the lowest indicator value, so stock A would get 1 point.
On Day 2 Stock B has a higher indicator value than stock A, so stock B would get 2 points.
On Day 2 Stock C has a higher indicator value than stock A and stock B, so stock C would get 3 points.
Can this be done with MetaStock?
Does anybody know if a different software that could do that?
Would I need the Metastock Developers Kit to program that?
Your help is very much appreciated.
Best regards
mhk1234
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers, Unverified Users Joined: 10/28/2004(UTC) Posts: 3,111 Location: Perth, Western Australia
Was thanked: 16 time(s) in 16 post(s)
|
You will need to normalise (or normalize) your indicator to account for the differences in the prices of the equities. Do a search of the forum for some of the many posts on how to achieve this. Once the indicator scale is the same across the entire spectrum, you can directly compare the values between stocks, you can employ the Explorer to do some of the work.
wabbit [:D]
|
|
|
|
Rank: Newbie
Groups: Registered, Registered Users Joined: 3/19/2010(UTC) Posts: 5
|
Dear Wabbit
thanks a lot for your answer.
I don't intend to run an exploration.
I intend to create what I call a "Ranking Indicator" that is plotted as a standalone indicator similar to an ERSA (External Relative Strength) indicator.
Example: If I would look at my AAPL chart, i would like to see:
- the daily price plot - the daily ADX values - the daily "Ranking Indicator" values (for day 1 (Mon), day 2 (Tue), day 3 (Wed) and so on.)
I looked at a lot of different post on the excellent Community but couldn't find anything.
I appreciate your help.
Best regards
mhk1234
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 7/25/2005(UTC) Posts: 1,042
Was thanked: 57 time(s) in 54 post(s)
|
Hi mhk
To rank securities in the way you suggest would require one of several things to happen. If Equis were to introduce a "Scan" function such as I believe AmiBroker has then it would be possible to make comparisons across a portfolio and plot rankings of whatever measure you required. Another possibility is for the FIRE add-on (formerly SpyGlass) to be enhanced to allow rankings other than just External Relative Strength (ERSA) as at present.
You need to understand that to rank a portfolio you must look at every security in the portfolio before deciding where the current security should be placed in the ranking scheme. There are two ways for Metastock to gain access to securities other than the currently active chart. One is by using the Security() function, and in practice you cannot realistically access more than somewhere between 25 and 75 securities at any one time using that function. Obviously this won't allow you to rank the S&P 500, and anyway it would be very slow retrieving data from just 25 securities.
The second way to gain access to all securities in a portfolio (or whatever) is to use the Explorer. I have demonstrated in issues of the MSTT newsletter how to approximate a SpyGlass ERSA ranking, and the method could be applied to virtually any criteria you can think of. With this ranking method the resulting numbers or percentages are different from ERSA results bur real percentages rather than being evenly distributed between 0% and 99%.
The problem with the Explorer is that it processes securities serially (one security at a time), and for that reason a ranking even on the current bar cannot be made until the exploration has been completed (and then by sorting the report is produces). Since the Explorer can only return a result as at the last bar we're left with a ranking for that bar only - not really what you have in mind.
There's another possibility (one that works but which in not as sophisticated as you'd want it to be) - which I've also demonstrated in MSTT. Harry Ward built a monthly fund trading system around it. The system buys the top 6 funds (by ROC ranking) and sells any fund that falls out of the top 6. The method used to rank fund history for the purpose of back-testing the system generates and stores the top 6 rankings as global variable arrays kept by the GV DLL. To build each successive ranking it's necessary to run one exploration across all securities. To build rankings for the top six funds requires six explorations. The method can be expanded to accommodate more rankings but there are a number of drawbacks to the method. Obviously the number of explorations required is one of them. Another is that the data arrays created are temporary and are lost when MetaStock is closed.
My point is that there are partial solutions already available but more sophisticated solutions are harder to come by. You can either use what is available, constantly fret over what's not avaiable, or go ahead and create your own solutions. Good luck with whatever route you choose to take.
Roy
|
|
|
|
Rank: Newbie
Groups: Registered, Registered Users Joined: 3/19/2010(UTC) Posts: 5
|
Dear Roy
thank you very much for your answer, I really do appreciate your help.
Your answer unfortunately confirms what I thought.
I will check out your newsletter, Fire and Amibroker.
I believe that a "Ranking indicator" would be very beneficial and could give excellent signals in conjunction with a moving average.
May I ask you one more question. Do you use the Metastock Developers Kit or Vitamin-C for Metastock?
If so, how would you rate these products.
I wish you a nice and successful week.
Best regards
mhk1234
|
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 7/25/2005(UTC) Posts: 1,042
Was thanked: 57 time(s) in 54 post(s)
|
Hi mhk
I do have the MDK but haven't acquired the skills to make use of it yet so can't make a valid judgement. :-( As for Vitamin C, if I was anywhere near competent with C++ I'd probably give it a go.
Roy
|
|
|
|
Users browsing this topic |
Guest (Hidden)
|
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.