<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" ><generator uri="https://jekyllrb.com/" version="3.10.0">Jekyll</generator><link href="https://davis-berlind.github.io/feed.xml" rel="self" type="application/atom+xml" /><link href="https://davis-berlind.github.io/" rel="alternate" type="text/html" /><updated>2025-09-04T08:33:51+00:00</updated><id>https://davis-berlind.github.io/feed.xml</id><title type="html">Davis Berlind</title><subtitle>Statistics PhD Candidate @ UCLA</subtitle><author><name>Davis Berlind</name><email>dberlind@ucla.edu</email></author><entry><title type="html">Detecting Changes in Daily Step Count</title><link href="https://davis-berlind.github.io/posts/2025/09/step-count/" rel="alternate" type="text/html" title="Detecting Changes in Daily Step Count" /><published>2025-09-04T00:00:00+00:00</published><updated>2025-09-04T00:00:00+00:00</updated><id>https://davis-berlind.github.io/posts/2025/09/step-count</id><content type="html" xml:base="https://davis-berlind.github.io/posts/2025/09/step-count/"><![CDATA[<meta http-equiv="refresh" content="0; url=/mich/articles/step_count.html" />

<p>If you are not redirected, <a href="/mich/articles/step_count.html">click here</a>.</p>]]></content><author><name>Davis Berlind</name></author><category term="change-point detection" /><category term="Bayesian statistics" /><summary type="html"><![CDATA[Using MICH to detect changes in my daily step count.]]></summary></entry><entry><title type="html">Community Detection with Dirichlet Process Prior</title><link href="https://davis-berlind.github.io/posts/2022/06/dirichlet-monk-community-detection/" rel="alternate" type="text/html" title="Community Detection with Dirichlet Process Prior" /><published>2022-06-10T00:00:00+00:00</published><updated>2022-06-10T00:00:00+00:00</updated><id>https://davis-berlind.github.io/posts/2022/06/dirichlet-monks</id><content type="html" xml:base="https://davis-berlind.github.io/posts/2022/06/dirichlet-monk-community-detection/"><![CDATA[<meta http-equiv="refresh" content="0; url=/html_posts/2022-06-10-dirichlet-monks.html" />

<p>If you are not redirected, <a href="/html_posts/2022-06-10-dirichlet-monks.html">click here</a>.</p>]]></content><author><name>Davis Berlind</name></author><category term="Bayeseian nonparametrics" /><category term="community detection" /><category term="networks" /><category term="Dirichlet process" /><summary type="html"><![CDATA[Implementing Bayesian nonparametric community detection for Sampson's monks.]]></summary></entry><entry><title type="html">A Note on Dirichlet Process Priors, Bernstein-von Mises, and Ray and van der Vaart (2021)</title><link href="https://davis-berlind.github.io/posts/2022/06/bvm-note/" rel="alternate" type="text/html" title="A Note on Dirichlet Process Priors, Bernstein-von Mises, and Ray and van der Vaart (2021)" /><published>2022-06-09T00:00:00+00:00</published><updated>2022-06-09T00:00:00+00:00</updated><id>https://davis-berlind.github.io/posts/2022/06/bvm-note</id><content type="html" xml:base="https://davis-berlind.github.io/posts/2022/06/bvm-note/"><![CDATA[<meta http-equiv="refresh" content="0; url=/html_posts/2022-06-09-bvm-note.html" />

<p>If you are not redirected, <a href="/html_posts/2022-06-09-bvm-note.html">click here</a>.&lt;
</p>]]></content><author><name>Davis Berlind</name></author><category term="Bernstein-von Mises" /><category term="Dirichlet process" /><category term="Bayesian non-parametrics" /><category term="statistical theory" /><summary type="html"><![CDATA[A discussion of the history and some of the basic properties of the Dirichlet process, the Bernstein-von Mises Theorem, and the results of Ray and van der Vaart (2021).]]></summary></entry><entry><title type="html">Bayesian Record Linkage and Binary Classification</title><link href="https://davis-berlind.github.io/posts/2022/06/bayesian-rl-logit/" rel="alternate" type="text/html" title="Bayesian Record Linkage and Binary Classification" /><published>2022-03-18T00:00:00+00:00</published><updated>2022-03-18T00:00:00+00:00</updated><id>https://davis-berlind.github.io/posts/2022/06/record-linkage-logit</id><content type="html" xml:base="https://davis-berlind.github.io/posts/2022/06/bayesian-rl-logit/"><![CDATA[<meta http-equiv="refresh" content="0; url=/html_posts/2022-03-18-record-linkage-logit.html" />

<p>If you are not redirected, <a href="/html_posts/2022-03-18-record-linkage-logit.html">click here</a>.&lt;
</p>]]></content><author><name>Davis Berlind</name></author><category term="Bernstein-von Mises" /><category term="Dirichlet process" /><category term="Bayesian non-parametrics" /><category term="statistical theory" /><summary type="html"><![CDATA[A model for Bayesian record linkage and logistic regression with exact error propagation.]]></summary></entry><entry><title type="html">Visualizing Changes to the Yield Curve in 3D</title><link href="https://davis-berlind.github.io/posts/2020/06/yield-curve/" rel="alternate" type="text/html" title="Visualizing Changes to the Yield Curve in 3D" /><published>2020-06-20T00:00:00+00:00</published><updated>2020-06-20T00:00:00+00:00</updated><id>https://davis-berlind.github.io/posts/2020/06/yield-curve</id><content type="html" xml:base="https://davis-berlind.github.io/posts/2020/06/yield-curve/"><![CDATA[<p>For better or worse, covering changes to the shape of the US Treasury <em>yield curve</em>
has become a persistent feature of economics journalism. The <a href="https://shiny.posit.co/">Shiny</a> 
app gives a simple way to visualize the evolution of the curve over time.</p>

<iframe src="https://davis-berlind.shinyapps.io/treasury-yield/" width="100%" height="725"></iframe>
<p><br /></p>

<p>When the US government wants to borrow money, the <a href="https://en.wikipedia.org/wiki/United_States_Department_of_the_Treasury">Treasury</a>
issues debt. This debt may take the form of a Treasury Bill, Note, or Bond depending on its 
<a href="https://www.investopedia.com/terms/t/termtomaturity.asp">term to maturity</a>, i.e. the length of
time the government is asking to borrow money for, and collectively these kind of debt instruments
are called <em>Treasuries</em>.</p>

<p>When purchasing Treasuries, one has to keep track of the <a href="https://www.investopedia.com/terms/p/parvalue.asp">par value</a>,
the <a href="https://www.investopedia.com/terms/c/coupon-rate.asp">coupon rate</a>,
and the price. The par value is the underlying value of the bond, i.e. what the government owes
you. If you buy a ten year Treasury Note with a \$1,000 par value, then at the end of those ten
years the government will pay you back \$1,000. The coupon rate is what we might commonly call
the interest rate. Every year you hold the bond, the government will pay you an additional sum
equal to the coupon rate times the par value. So continuing the previous example, if you buy a 
ten year Treasury Note with a \$1,000 par value and a five percent annual coupon, then once
every year (until the bond matures) the government will pay you \$50 for lending them your
money.</p>

<p>However, when most Treasuries are purchased, whether through direct auctions by the government
or a secondary market, the price paid by the buyer is rarely equal to the par value. Instead,
Treasuries are bought and sold at at a <em>discount</em> or <em>premium</em> on the par value. For instance,
if the stock market is slumping and investors are searching for someplace safe to keep their money, 
they may turn to Treasuries, thereby driving up demand and increasing the price above par. 
For example, You might be willing to pay \$1,100 for a \$1,000 par value bond based on the 
security it gives you, i.e. you are paying a \$100 premium. This is where the concept of yield 
comes in. The yield is simply the annual coupon payment divided by the market price of the bond. 
So if you purchased a ten year Treasury Note with a \$1,000 par value and a five percent annual 
coupon for \$1,100, then your yield would be $\frac{0.05 \times 1000}{1100} = 0.0455$; in other 
words, the yield would be 4.55%.</p>

<p>The yield curve simply comes from plotting the bond yields of Treasuries at each maturity term
length. Typically, the yield curve is upward sloping, indicating that the longer you
are willing to lend out your money, i.e. the more <a href="https://www.investopedia.com/terms/i/interestraterisk.asp">interest rate risk</a>
you are willing to take on, the more you will be paid.<sup id="fnref:1" role="doc-noteref"><a href="#fn:1" class="footnote" rel="footnote">1</a></sup> In rare cases, short-term yields 
can actually rise above long-term yields, in which case the curve is said to be <em>inverted</em>. 
<a href="https://en.wikipedia.org/wiki/Campbell_Harvey">Campbell Harvey</a>’s 1986 dissertation linked 
inversions of the curve to near-term economic downturns, and in the intervening years the 
inverted yield curve has demonstrated remarkable accuracy for predicting recessions.</p>

<blockquote>
  <p>The ten-year/two-year Treasury spread is one of the most reliable leading indicators of 
recession within the following year. For as long as the Fed has published this data back to 1976, 
it has accurately predicted every declared recession in the U.S., and not given a single false
positive signal.<sup id="fnref:2" role="doc-noteref"><a href="#fn:2" class="footnote" rel="footnote">2</a></sup></p>
</blockquote>

<p>Even the current 2020 COVID-19 recession was preceded by a yield curve inversion in August 2019
(most will point to this as a technicality, but it’s a perfect record nonetheless). Here’s the 
<a href="https://davis-berlind.shinyapps.io/treasury-yield/">link</a> for direct access to the Shiny app. 
The <a href="https://github.com/davis-berlind/treasury-yield">source code</a> is also available on my 
<a href="https://github.com/davis-berlind">GitHub</a>.</p>

<div class="footnotes" role="doc-endnotes">
  <ol>
    <li id="fn:1" role="doc-endnote">
      <p>In addition to being upward sloping, under normal assumptions the yield curve is concave, indicating decreasing marginal returns to assuming more credit risk. <a href="#fnref:1" class="reversefootnote" role="doc-backlink">&#8617;</a></p>
    </li>
    <li id="fn:2" role="doc-endnote">
      <p><a href="https://www.investopedia.com/terms/i/invertedyieldcurve.asp">Jime Chappelow, Investopedia</a> <a href="#fnref:2" class="reversefootnote" role="doc-backlink">&#8617;</a></p>
    </li>
  </ol>
</div>]]></content><author><name>Davis Berlind</name></author><category term="data visualization" /><category term="economics" /><summary type="html"><![CDATA[A Shiny web application to visualize the yield curve of US Treasuries as a 3D surface.]]></summary></entry><entry><title type="html">Modeling the spread of an Infection on a Random Graph</title><link href="https://davis-berlind.github.io/posts/2020/04/infection-simulation/" rel="alternate" type="text/html" title="Modeling the spread of an Infection on a Random Graph" /><published>2020-04-24T00:00:00+00:00</published><updated>2020-04-24T00:00:00+00:00</updated><id>https://davis-berlind.github.io/posts/2020/04/covid-graph</id><content type="html" xml:base="https://davis-berlind.github.io/posts/2020/04/infection-simulation/"><![CDATA[<meta http-equiv="refresh" content="0; url=/html_posts/2020-04-24-covid-graph.html" />

<p>If you are not redirected, <a href="/html_posts/2020-04-24-covid-graph.html">click here</a>.&lt;
</p>]]></content><author><name>Davis Berlind</name></author><category term="python" /><category term="cluster computing" /><category term="epidemiology" /><summary type="html"><![CDATA[Using python and high-performance computing to model the spread of an infectious disease across a random graph.]]></summary></entry></feed>