Can WealthLab allow me to rank each member of a portfolio? E.g. Find the top 10 percent of highest ROC.
Thanks
Size:
Color:
Check out the "Symbol Rotation" strategy folder. Click "Download" in the "Open Strategy" dialog to get more. They're widely discussed on the forum.
Size:
Color:
Thanks, I'll check them out.
Size:
Color:
I'm a bit confused having looked at these strategies. All I wish to do is allow an indicator to determine the top or bottom percentage of value. Let's say (ATRP.Series(Bars, 5) is within the top 10 percent of all stocks within the SP 500. Print stocks. TIA
Size:
Color:
Size:
Color:
QUOTE:
10% of 500 stocks is 50. Use this as your "n Symbols". PrintDebug prints.
I did look through the material. They gave an example using the highest high as of bar. I can't quite understand how to apply the logic here. I would be grateful if you can supply the code. This will provide an example for other indicators I wish to incorporate.
Size:
Color:
I have no idea where you found the example using the "highest high" but in fact not in the
Wiki FAQ I referred to. There is no shortage of examples in the Symbol Rotation folder showing all kinds of DataSeries like volatility, ROC, RSI, either top (strongest stocks) or bottom (weakest ones) - the world doesn't need more examples than the dozen at your fingertips. Just replace one series (RSI) with another (ATRP). If unsure how to do so, see those examples along with DataSeries chapters in the WealthScript Guide/QuickRef. Just a one-liner exemplified in the FAQ.
Size:
Color:
OK. I am still unable to figure this out. How then can I see the results of the top 10 percent of stocks with the highest ATRP? Is there a specific rotation strategy that will allow me to rank the stocks in a portfolio. I just tried "Weekly Oversold Rotation" but was unable to figure what I wish to do. Sorry I might seem rather obtuse. Many thanks for your help.
Size:
Color:
Okay, here's a simple example listing top/bottom stocks by ROC as of the last bar. Before running, click "References..." in the Editor, check
System.Core and click OK. The code is designed to be run on
single symbol only. Since you'd be inevitably asking about ATRP I've thrown it in there ;)
CODE:
Please log in to see this code.
Size:
Color:
Thank you Eugene. I'm looking at it now.
Size:
Color:
Thank you Eugene. I'm receiving a runtime error: Attempting to Deserialize an empty stream. I looked through multiple single stocks in different data sets. It runs on any stock within "Indexes" and returns one stock with " Listing Top 1 stock". Is there anything I might do to understand and change this?
Size:
Color:
Size:
Color: