# Formula that predicts whether one is better off investing or paying down debt

This is more of a statistics/probability question but the implications for personal finance are obvious.

Let's say you have extra cash (assume tax-advantaged space is already maxed out) and are weighing investing versus paying down debt at some interest rate. I am interested in a formula that predicts the probability of investing outperforming paying down debt over a given length of time. Variables would be average annual investing return and standard deviation (e.g. 11.4% and 13.2%, respectively, via this article), debt interest rate, and number of years. Let's assume investing returns are normally distributed.

Of course the pure mathematical answer is you should always invest if your investment rate of return is higher than your interest rate. But if your rate of return is only slightly higher than your interest, and paying off debt has a standard deviation of 0% versus much higher for investments, the probability of investing coming out ahead might be just over 50% and one would deem it not worth the risk.

• Just a small addendum: One might need to consider the tax benefits of deducting loan interest (in the case of student loans/mortgages) to get the proper answer
– Noah
Oct 17 '14 at 14:33
• @Noah: True, though I think this could be accomplished by multiplying your interest rate by 1 - tax rate. For example, if I have a 4% loan and the entire amount would be taxed at 25%, I can consider it a 3% loan. Oct 17 '14 at 14:46
• Note, I show US returns for the period 1950-2013 as 11.38. I don't know why Fidelity rounded down. And I see a STDEV as 17.8%, far higher than the Fidelity article. Oct 17 '14 at 15:08
• Ok, so where's the formula? I'm in a 30-yr loan but I plan on selling in say 7-10 years. So, whoever the genius is that puts this spreadsheet together, it would be nice to compare a monthly amortization table for the mortgage to the monthly return on the investment. Come on, I know someone out there is just itching to throw this thing together!
– user28942
May 15 '15 at 13:23
• @Jason - note, you posted this as an answer. I've moved it to show as a comment. In effect, it's more of a 'bump,' as it brought the post to the first page this moment. May 15 '15 at 13:55

you should always invest if your investment rate of return is higher than your interest rate

There are too many variables to give an exact answer here, in my opinion. The main reason is that one variable isn't easy to quantify - One's risk tolerance.

Clearly, there's one extreme, the 18% credit card. Unless you are funding loanshark type rates of 2%/week, it's safe to say that 18% debt should take priority over any investments, except for the matched 401(k) deposits.

Do I prepay my sub 4% mortgage or invest?

In this case, (and to Noah's comment) the question is whether you can expect a post-tax return of over 3% during your time horizon. I look at the return for 15 years from 1998-2013 and see a 6% CAGR for the S&P. I chose 15 years, as the choice is often one of paying a 30 year mortgage faster, as fast as 15. The last 15 years offer a pretty bad scenario, 2 crashes and a mortgage crisis. 6% after long term gains would get you 5.1% net.

You can pull the data back to 1871 and run CAGR numbers for the timeframe of your choosing. I haven't done it yet, but I imagine there's no 15 year span that lags the 3% target I cite.

What makes it more complex is that the investment isn't lump sum. It may not be obvious, but CAGR is a dollar invested at T=0, and returns calculated to T=final year. It would take a bit of spreadsheeting to invest the extra funds every month/year over your period of analysis.

In the end, there are still those who will choose to pay off their 4% mortgage regardless of what the numbers show. Even if the 15 year result showed worst case 3.5% (almost no profit) and an average 10%, the feeling of risk is more than many will want.

• It is certainly a question of risk profile, and I think this calculation would be an excellent way to quantify that. If you could tell somebody that they only have a 51% chance of investing performing better than paying down debt, almost everybody would pay down the debt. If the chance was 99%, most people would probably invest. Oct 17 '14 at 15:23
• @CraigW - not tough to spreadsheet this. If the chance were 100% and worst case scenario were a positive 1% (i.e. higher than debt), I'd still think most would still not invest. Most humans lag the market by many percent. An average 10% return shows up as sub 5% once investor behavior is injected. See my answer at money.stackexchange.com/questions/14144/… Oct 17 '14 at 15:39
• I see the question as asking for the probability, which doesn't necessarily depend on the risk tolerance. Your risk tolerance involves how you translate the probabilities into actual decisions. I think there is enough info to calculate a simple probability, but that probability may not be that useful in maing a decision. Oct 17 '14 at 19:46
• @BrenBarn for me personally I think this would be the most informative number to know. I've already made the decision to invest over paying extra principal on my mortgage, but it'd be nice to know how likely that is to be the "right" decision in hindsight. Oct 17 '14 at 20:17
• @BrenBarn - You are absolutely right. The question is one of facts, probability, and numbers. Whether one acts on the data is different, not part of the question. Oct 17 '14 at 21:53

I ended up writing a simulation in R. Here is my code:

``````investing.mean.return<-0.114
investing.mean.stdev<-0.132
pay.down.loan.return<-0.04375
tax.rate<-0.28+0.093
years<-25
trials<-10000

investing.annualized.returns<-c()
pay.down.loan.annualized.return<-((1+(1-tax.rate)*pay.down.loan.return)^years)^(1/years)-1
p.value<-0
for(i in 1:trials) {
investing.returns<-rnorm(years, investing.mean.return, investing.mean.stdev)
investing.annualized.return<-prod(1+investing.returns)^(1/years)-1
p.value<-p.value+(investing.annualized.return<=pay.down.loan.annualized.return)
investing.annualized.returns<-c(investing.annualized.returns, investing.annualized.return)
}
p.value<-p.value/trials
h<-hist(investing.annualized.returns*100, breaks=100, plot=F)
plot(h, freq=FALSE, xlab="annualized investing return (%)", ylab="probability", main=paste0(p.value*100, "% chance of paying down loan outperforming investing"))
abline(v=pay.down.loan.annualized.return*100, lty="dashed", col="red")
legend(x=0, y=mean(c(min(h\$density), max(h\$density))), paste0("annualized pay down loan return (", round(pay.down.loan.annualized.return*100, 2), "%)"), lty="dashed", col="red")
``````

It produces a plot like this:

This code assumes you have a lump sum and either wish to pay down a loan or invest it all immediately. Feedback welcome.

• A 1 in 600 (or so) chance that the investing is a bad choice, yet so many choose this option (of paying the low interest loan). Jun 5 '15 at 1:53

Although I don't think you need to factor in risk tolerance to get the probabilities, I agree with JoeTaxpayer that you will need to factor in risk tolerance in order to make a practical decision about what to do. In fact, I think that to make a practical decision you will need more than the specific probability you ask for you in the question; rather, you would like to see the complete probability distribution of possible outcomes.

In other words, it's not enough to know that there is a 51% chance that investing will outperform paying down debt. You actually need to know much it outperforms when it does outperform, and how much it underperforms when it underperforms. As JoeTaxpayer's comment suggests, you might not choose to make an investment that had a 99% chance of outperforming debt payment by 1%, and a 1% chance of underperforming by 99%.

I think it possible to address these questions by doing simulations. This can be done even with a spreadsheet, but more flexibly with simple programming. Essentially you can create some kind of probabilistic model of the various factors (e.g., chance that your investment will go up or down) and see what actually happens: how often you lose a lot of money, lose a little money, gain a little money, or gain a lot of money. Then based on that you can consult your inner spirit animal to decide whether the probability distribution of possible gains outweighs that of possible losses.

The formula you are looking for is pretty complicated. It's given here: http://itl.nist.gov/div898/handbook/eda/section3/eda3661.htm

You might prefer to let somebody else do the grunt work for you. This page will calculate the probability for you: http://stattrek.com/online-calculator/normal.aspx. In your case, you'd enter mean=.114, standard deviation=.132, and "standard score"= ... oh, you didn't say what you're paying on your debt. Let's say it's 6%, i.e. .06. Note that this page will give you the probability that the actual number will be less than or equal to the "standard score". Enter all that and click the magic button and the probability that the investment will produce less than 6% is ... .34124, or 34%.

The handy rule of thumb is that the probability is about 68% that the actual number will be within 1 standard deviation of the mean, 95% that it will be within 2 standard deviations, and 99.7% that it will be within 3. Which isn't exactly what you want because you don't want "within" but "less than". But you could get that by just adding half the difference from 100% for each of the above, i.e. instead of 68-95-99.7 it would be 84-98-99.9.

Oh, I missed that in a follow-up comment you say you are paying 4% on a mortgage which you are adjusting to 3% because of tax implications. Probability based on mean and SD you gave of getting less than 3% is 26%.

I didn't read the article you cite. I assume the standard deviation given is for the rate of return for one year. If you stretch that over many years, the SD goes down, as many factors tend to even out. So while the probability that money in a given, say, mutual fund will grow by less than 3% in one year is fairly high -- the 25 - 35% we're talking here sounds plausible to me -- the probability that it will grow by an average of less than 3% over a period of 10 or 15 or 20 years is much less.

Further Thought

There is, of course, no provably-true formula for what makes a reasonable risk. Suppose I offered you an investment that had a 99% chance of showing a \$5,000 profit and a 1% chance of a \$495,000 loss. Would you take it? I wouldn't. Even though the chance of a loss is small, if it happened, I'd lose everything I have. Is it worth that risk for the modest potential profit? I'd say no. Of course to someone who has a billion dollars, this might be a very reasonable risk. If it fails, oh well, that could really cut in to what he can spend on lunch tomorrow.

• I realize you can do the math or look up the numbers for a normal distribution, but I wasn't sure how to deal with multiple years. Hence the simulation I wrote. May 20 '15 at 18:43

Old question I know, but I have some thoughts to share.

Your title and question say two different things. "Better off" should mean maximizing your ex-ante utility. Most of your question seems to describe maximizing your expected return, as do the simulation exercises here. Those are two different things because risk is implicitly ignored by what you call "the pure mathematical answer." The expected return on your investments needs to exceed the cost of your debt because interest you pay is risk-free while your investments are risky.

To solve this problem, consider the portfolio problem where paying down debt is the risk-free asset and consider the set of optimal solutions. You will get a capital allocation line between the solution where you put everything into paying down debt and the optimal/tangent portfolio from the set of risky assets.

In order to determine where on that line someone is, you must know their utility function and risk parameters. You also must know the parameters of the investable universe, which we don't.