l-distribution" class="section level3 unnumbered">
<h3>Exponential distribution</h3>
<p>If Stan didn’t happen to include the exponential distribution, it
could be coded directly using the following assignment statement,
where <code>lambda</code> is the inverse scale and <code>y</code> the sampled
variate.</p>
<pre><code>target += log(lambda) - y * lambda;</code></pre>
<p>This encoding will work for any <code>lambda</code> and <code>y</code>; they can
be parameters, data, or one of each, or even local vari