S&P 500 Shillerforward PriceEarnings ratio (P/E) versus 10 year Treasury bond rates
How does one estimate an appropriate PriceEarnings ratio (P/E) should be at a given time? This may help in judging whether stocks, or in the case here, the Standard and Poor's 500 index (S&P 500), are perhaps [over, under]valued, and whether you need to take a closer look to make sure that other factors justify going ahead with their [sale, purchase]. Sometimes my thinking is based on outmoded "rules of thumb" that fail when applied to rapidly changing market conditions, so this is of interest to me.
In my view, fundamental analysis is a very important basis for any such decision, so criteria such as PE ratios are only supplementary to that.
A very [simple, basic] model is shown below as a starting point. While something far more [sophisticated, proven] could be pulled out of a standard textbook, by doing it "blind" by myself, I can better appreciate what others have done before me (when and if I get around to going further with this), and it's a powerful way to learn when complimented with further reading. It's also a great way to make a fool of myself (been there many times, done that).
This webpage was [inspired by, based on] :

How Much Do Interest Rates Affect the Market's P/E Ratio?,
Taking a look at the relationship between the two, Ben Reynolds, July 22, 2016

P/E Ratios & Interest Rates: A Formula for Fair P/E Ratios Incorporating Interest Rates,
Ben Reynolds, Updated August 22nd, 2018
 multpl.com
17Apr2021 update : see also!! :

Qiang Zhang 30Jan2021 Price Earning Ratio model  This is similar to, but better than, my own model below. His github has several other interesting investmentrelated postings, including BlackScholes derivative pricing.
 In 202021, someone else showed a model of P/E versus Tbills, but I can't find the reference... there are likely thousands of such models over history.
Image of one result from the model :
Don't pay too much attention to the results. As with any [parametric, statistical] model, you can often fudge things to get what you want. More important is just a "feel" for how parameters MIGHT affect results in a very rough sense, and getting a feel for what might done to improve the [concepts, model]. While "A picture is worth a thousand words", I say that "A good question is worth a thousand answers".
Howell's "[simplest, basic] model" derivation :
(This needs to be cleaned up, as it went through 3 iterations.)
Nomenclature :
disRate = discount rate, different factors are used for [Tbills, SP500]
FV = Future Value
PV = Present Value
SP500  refers to the Standard & Poors 500 index
SP500_earningsFutureDis = future earnings projected for years_SP500, discounted to today
SP500_growFuture  assumed growth rate in S&P500 over years_SP500
t10  interest rate on the 10year Tbill
Treas  refers to Treasury bond (10 year bond used in example)
Treas_pay0  cost today of a Treasury bond (given the rate)
years_SP500 = the number of years forward that earnings are taken into account
years_Tbill = the number of years that the Tbill is based on
Do present value calculations for simplicity :
from : https://www.wikihow.com/CalculateanAnnualPaymentonaLoan
(binomial theorem?)
annuity payment C = r*P / (1  (1 + r)^(n))
https://www.investopedia.com/retirement/calculatingpresentandfuturevalueofannuities/
Value at end FV = C*((1+r)^n  1)/r
Treasury bonds :
Treas_PV
= Treas_FV / (1 + Treas_disRate)^years_Tbill
= Treas_pay0*(1 + t10)^years_Tbill / (1 + Treas_disRate)^years_Tbill
= Treas_pay0*((1 + t10) / (1 + Treas_disRate))^years_Tbill, given that both are assumed constant in this model
S&P 500 index :
SP500_priceNow = SP500_earningsFutureDis * SP500_PEnow
try :
SP500_earningsFutureDis
= SP500_earningsNow * sum[y = 1 to years_SP500; {(1+SP500_earnGrwth)/(1+SP500_disRate)}^y]
Notice that this model looks ONLY to the future using projected earnings, rather than taking into account the Shiller P/E ratios and current market price! Consideration of those two factors could greatly improve the reliability of the model, but that is for some time in the future... (just a maybe  not so likely for me).
Now look at "balance" of [Treas_PV, SP500_PV] for equal 1 k$ investment :
1 k$ Treas_pay0 = 1 k$ @ SP500_priceNow
Treas_pay0 * (1 + t10)^years_Tbill / (1 + Treas_disRate)^years_Tbill
= SP500_earningsNow * sum[y = 1 to years_SP500; {(1+SP500_earnGrwth)/(1+SP500_disRate)}^y]
But for equal initial investments, also :
Treas_pay0 = SP500_priceNow = SP500_PEnow * SP500_earningsNow
so :
SP500_PEnow * SP500_earningsNow * (1 + t10)^years_Tbill / (1 + Treas_disRate)^years_Tbill
= SP500_earningsNow * sum[y = 1 to years_SP500; {(1+SP500_earnGrwth)/(1+SP500_disRate)}^y]
or :
SP500_PEnow
= sum[y = 1 to years_SP500; {(1+SP500_earnGrwth)/(1+SP500_disRate)}^y]
/ {(1 + t10)^years_Tbill / (1 + Treas_disRate)^years_Tbill}
This is the model used.
LibreOffice Calc spreadsheet implementation :
see Howell  SP500 PE Shiller ratios versus 10 year Treasury bond yields, with earnings growth & discount factors.ods
Note that Microsoft Exel will often complain that it cannot load the file, but go ahead with the loading anyways. There is a good degree of compatibility between Exel and LibreOffice Calc, with the important exception of macros, which have to be rewritten. I have not used macros in thispreadsheet.
The spreadsheet is very simple, allowing changes to the discount factors for [earnings growth, Tbills], resulting in immediate updating of the graph. Other changes are also easy for those familiar with using spreadsheets, such as :
 changing the number of years_SP500 that future earnings are used to calculate today's PE ratio.
 changing the basis of the model (the formulae)
 allowing for discount factors to increase over time
 etc
Spreadsheets are NOT [flexible, powerful] for much more complex models than the [simple, basic] model shown above, unless one uses macros. Or perhaps better stated, I prefer to work with programming languages that I know can easily get the job done, and that make it [easy, fast] to [think, work] at more abstract levels. If I ever find the time, I will continue instead with the QNial programming language to do complex models. Explanations and the resulting graphs would then be posted to this webpage. Don't hold your breath  this isn't a focus of mine, and I need to focus on project priorities in completeeldifferent subject areas (notably [artificial neural networks, fundamental theoretical physics]).
WARNINGS
First of all, I have zero [expertise, experience] in this area, even though I've always been interested in [business, economics, finance, markets] but never found time to look into it. On occasion over past decades, I have done fundamental analysis of individual companies (financial statements, business and market outlook, competitive scene, etc) but only with limited time. My favourite was always tiny [technology, biotech] startup companies with an interesting scientific concept and not much of an organisation. But most of theose are killed off quickly, both in a scientific and business sense. I had terrible investment results, but of fun, and I got to know very interesting people with dreams!
This model :
 has not been researched at all  I threw it together quickly after seeing Ben Reynolds' webpages, and I have not gone through Shillers' books or published papers. These will have done the same thing, and much more, properly!
 there is a temporal mismatch between the years_SP500 and the 10 year Tbill
 will have mathematical errors, as I did it in one day, and did not do rigorous checking of results.
 is unrealistically simple, and makes questionable assumptions.
 has not been validated  the intent here is mainly to play with a tool, and think of how better to do the mathematical modeling of more complex [time series, predictive drivers] of the markets.
 has not been applied to the data as per Ben Reynolds' graph, which would be an important reality check. [Labelling, coloring] of the data points on Ben's graphs with at least the years_Tbilly Tbill rates would be a first step to doing the comparison to this [simple, basic] model.
 does not account for [dividends, inflation, investor "favourites", etc] at this stage.
 Notice that for SP500 earnings growth > Discount Factor (DF), the growth means that later years contributions to Present Value INCREASE! This may not be realistic, as it implies that further years should be included, and for infinite time, the PV would go to to infinity! Some exceptions are anticipated  Tesla is one example of expectations by many for a major change to electric in the automobile industry, will huge consequences. [Microsoft, Apple, etc] are perhaps past examples.
 is hugely [incomplete, incoherent].
Obviously, do NOT this for any real work that you have! It's just a toy!
Future possibilities :
A key interest that I have is with concepts that identify and apply basic DRIVERs of phenomena, beyond conventional approaches. For example, you will have noticed that weather, climate]modelling ignores the most basic drivers of the phenomena that they are dealing with (weather  largely a NavierStokes engine with [heat, mass transfer], blind to most fundamentals, climate  what a disgrace!).
 Definitely  the model should be applied to various historical stretches of the SP500, using "foreknowledge" of the actual earnings. This key check is essential.
 timevarying [SP500_growFuture, etc]  there is little chance of growth rates lasting more than a year or two, especially  > 20%. Frankly, they are constantly changing yeartoyear in a big way. The time series approach mentioned below is a simple basis for anticipating this in a statistic manner as a start. Other approaches get more into predictions based on some concept or another.
 market crashes etc  over a period of 20 years, for example, there is a hisgh chance of at least one or two occuring
 SP500 index, variable [dividends, internal investment & stock buybacks, earnings]  I won't be looking at these any time soon ....
 time series analysis (Fourier series, wavelet analysis, neural networks, etc)
 fractal & chaos theory
 Elliot Wave Theory, notable Robert Prechter (including Socionomics). Amoung many, many fun topics, the arguments presented about how the Fed FOLLOWSnterest rates, only gng the impression of leading, is espectially relevant to theis webpage.
 Harry S. Dent Jr  demographics, with astounding successes in the past (at least twice on decadeorlongerout basis, perhaps a bit muffled with the last decade.
 Stephen Puetz  Universal Wave Series stunning results across a huge swath of subject areas!! eminds me of the system of 20+ Mayan calendars.
 Brian Frank of Frank funds  "SlaughterhouseFive (Hundred), Passive Investing and its Effects on the U.S. Stock Market"  Index fund [distortion, eventual destabilization] of the markets. This was a recent fascinating read for me. (MarketWatch 10Apr2020)
 psychology, sociology, history, astronomy, earth sciences (Puetz touches all of those and many more! Elliot wave also, with less of a timing basis and independent exogenous factors.)