Help needed with steady growth in a rank.

Hi all!!!

I need help with a ranking I’m trying to create. My idea is to find companies whose sales and earnings grow at modest but steady rate.

For instance like the pictures I attached here.

I tried with a ranking based on acceleration rules, but I do not get that kind of companies, or at list not all are like this.

Could anyone help me with the kind of rule or rules should I place in the ranking system?




What you’re looking for is the slope of a linear regression. The formula is below. (I can’t paste it into the middle of a post.)

This can be radically simplified if all the n’s and x’s you’re comparing are the same. Basically, you can just ignore the denominator since it’ll be exactly the same for every company you look at. Then you have just to plug the numbers in for n, x, and y in the numerator.

So let’s say you’re looking at the slope for the last seven years’ of sales. You can assign x’s as follows: current year could be 3, last year could be 2, and so on until 7 years ago would be -3. Then the formula would be simply 7*(-3sales(6,ann)-2sales(5,ann)-sales(4,ann)+sales(2,ann)+2sales(1,ann)+3sales(0,ann)). Why? Because the way you assigned x’s means that they add up to zero, so the part on the right half of the numerator gets zeroed out.


linear regression slope equation.png

Yuval’s solution gets you the slope but what you really want is the variance from the slope.

I suggest starting with:

LoopStdDev(“Sales(CTR,TTM)/Sales(CTR+1,TTM)”,12)

with lower is better ranking. This will give you steady TTM sales growth for the last three years. But you need to qualify this with:

Sales3YCGr%>0

or some minimum level of 3-yr growth either in the ranking system or as a buy rule.

SteveA

So, i’ll be Captain Obvious this morning and just note that;

7*(-3*sales(6,ann)-2*sales(5,ann)-sales(4,ann)+sales(2,ann)+2*sales(1,ann)+3*sales(0,ann))

can be written as;

7*LoopSum("Sales(3+CTR,ANN)*(-CTR)",7,-3,1)

In addition, since the sum of X terms is zero, the second term on the denominator is also zero and that the above LoopSum is off only by a constant scaling factor from the true regression value;

7*LoopSum("CTR*CTR",7,-3,1)

and since scaling factors don’t matter in rating systems, this is good enough;

LoopSum("Sales(3+CTR,ANN)*(-CTR)",7,-3,1)

but if you do want to rank something, make sure it’s already normalized, for example, something like this;

LoopSum("RoE%(3+CTR,ANN)*(-CTR)",7,-3,1)

Walter

Again, the slope gives the strength of the growth trend. What Monday appears to be asking for is the smoothness. So unless there is some magic here that I am missing, a slope calculation isn’t what is called for.

I have just tested my formula and on its own is not impressive, but when added with some other ranking factors gives some pretty good results, enough so that I am adding it to my arsenal. The lowest deviation of growth gets the highest ranking.

I have made a slight mod to the original equation as the growth should be calculated over 4 quarters, not 1. The modified formula for TTM over three years:

LoopStdDev(“Sales(CTR,TTM)/Sales(CTR+4,TTM)”,12)

If you want to measure 5 years instead then use:

LoopStdDev(“Sales(CTR,TTM)/Sales(CTR+4,TTM)”,20)

If you want the formula to span more than five years then you have to change from TTM to annual (ANN). This would be ten years:

LoopStdDev(“Sales(CTR,ANN)/Sales(CTR+1,ANN)”,10)

I agree with incorporating minimized StdDev like InspectorSector suggests.

Here’s a quick factor setup for this using up trending sales and net income. Some adjustments may be needed if you want to restrict to only positive net incomes, but the basic structure might be decent to work with. I eyeballed the results for some of the top companies and it seems to be in the right ballpark for type of companies you’re targetting.

https://www.portfolio123.com/app/ranking-system/360336

Hi all!!

THANKS Yuval, Steve, Walter and Spaceman for help me with that formula. Your are great!!

About that Steve is right, what I’m looking for is the smoothness of the sales.

By the way, I would like to post the results of all thouse formulas you suggested, because the results are very different.

I created a ranking for each formula, no other factors, to see how it works with my sim.

The one that works better is the one Steve suggested:

LoopStdDev(“Sales(CTR,TTM)/Sales(CTR+1,TTM)”,12)

with this rule in the Buy orders: Sales3YCGr%>0


But if I try with the second formula:

LoopStdDev(“Sales(CTR,TTM)/Sales(CTR+4,TTM)”,12)

The outcome is different…


About Yuval’s formula: 7*(-3sales(6,ann)-2sales(5,ann)-sales(4,ann)+sales(2,ann)+2sales(1,ann)+3sales(0,ann))

In “lower the better” ranking. This is the result in the same sim.


And, if I do the same with one of Walter’s formulas, this one for instance:

LoopSum(“Sales(3+CTR,ANN)*(-CTR)”,7,-3,1)

The results are similars to Yuval’s formula, but not identical…


Why the results of a formula that must do, more or less, the same, are so different???

Ah, by the way, when I looked at the holdings/historical financial trends, the charts who are more similar to my idea of “steady sales” where the one’s that Steve’s first formula returns.

James - it is the time frame that gives the variation in results. The first formula only looks back 3 years but on a quarterly basis. The last formula looks back 10 years but on an annual basis. Most of the stocks I rank are high growth stocks that haven’t been around for a long time so the 3-yr lookback is more appropriate for what I am interested in.

SteveA

Hello Steve.

Yes, it’s what I thought, but anyway I think the results are very different, I expected more similar results.

Anyway, do you know how to write Yuval’s formula for three years?

Perhaps like this:

3*(sales(2,ann)+2sales(1,ann)+3sales(0,ann))

James - I just realized you had put up a post with some graphs. Generally, I don’t work with the NO OTC Universe because there are too many junk and illiquid stocks. You aren’t showing any liquidity or price filters so it is hard to come to any conclusions. You might want to start with the PRussell3000 as the universe then add some liquidity and price filters. Just a suggestion.

As for Yuval’s formula, I don’t want to touch that. My math skills aren’t what they used to be and it isn’t clear to me what the formula is achieving, other than an approximation to the slope of past fundamentals, which is more of a strength indicator. If that is the case, higher is better, which might explain the so-so results you are getting with the formula. If you truly want to add a strength factor then I suggest sticking with the standard composite growth formulas that P123 provides, such as Sales3YCGr% with higher is better. For my purposes, I found that Sales3YCGr% works well in conjunction with the smoothness formula, but I focus on one specific area of the market only, so I can’t come to any general conclusions.

Hope that helps
Steve

Steve-

I’m working on a sim based on small caps (Market cap<300), then I think I need the “No OTC Universe” because I want to have Nasdaq stocks, Russell 3000 stocks and so…

And about Yuval’s formula do not worry, let’s see if Yuval appears here…

Thanks a lot for your comments and help.

You want higher is better with my formula and you wouldn’t use it in conjunction with three-year sales growth being positive. This formula measures the 7-year sales trend. If sales are improving it’s high, if sales are decreasing, it’s low.

Yuval,

How would be your formula for 3 year sales?

Maybe like this:

3*(sales(2,ann)+2sales(1,ann)+3sales(0,ann))

If you do it quarterly it would be LoopSum(“(6-CTR)*(Sales(CTR,Qtr)”,13,0). Annually it would be Sales(0,Ann)-Sales(2,Ann), but that won’t tell you much at all. By the way, I’m no longer feeling very confident about this approach.

Ok, thanks a lot for your help Yuval.

Can I ask why you are no longer confident about that approach?

I don’t think it works very well, that’s all.