Skip to content

Commit

Permalink
deploy: ce4efd3
Browse files Browse the repository at this point in the history
  • Loading branch information
s3alfisc committed Nov 26, 2024
1 parent 36ea725 commit dde54b3
Show file tree
Hide file tree
Showing 38 changed files with 2,761 additions and 2,843 deletions.
156 changes: 77 additions & 79 deletions changelog.html

Large diffs are not rendered by default.

111 changes: 54 additions & 57 deletions compare-fixest-pyfixest.html

Large diffs are not rendered by default.

9 changes: 3 additions & 6 deletions contributing.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head>

<meta charset="utf-8">
<meta name="generator" content="quarto-1.5.57">
<meta name="generator" content="quarto-1.6.37">

<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes">

Expand Down Expand Up @@ -69,10 +69,10 @@
<script src="site_libs/quarto-html/tippy.umd.min.js"></script>
<script src="site_libs/quarto-html/anchor.min.js"></script>
<link href="site_libs/quarto-html/tippy.css" rel="stylesheet">
<link href="site_libs/quarto-html/quarto-syntax-highlighting.css" rel="stylesheet" id="quarto-text-highlighting-styles">
<link href="site_libs/quarto-html/quarto-syntax-highlighting-29e2c20b02301cfff04dc8050bf30c7e.css" rel="stylesheet" id="quarto-text-highlighting-styles">
<script src="site_libs/bootstrap/bootstrap.min.js"></script>
<link href="site_libs/bootstrap/bootstrap-icons.css" rel="stylesheet">
<link href="site_libs/bootstrap/bootstrap.min.css" rel="stylesheet" id="quarto-bootstrap" data-mode="light">
<link href="site_libs/bootstrap/bootstrap-35b661c73272c531296c3b360bfb6fcf.min.css" rel="stylesheet" append-hash="true" id="quarto-bootstrap" data-mode="light">
<script id="quarto-search-options" type="application/json">{
"location": "navbar",
"copy-button": false,
Expand Down Expand Up @@ -413,8 +413,6 @@ <h3 class="anchored" data-anchor-id="installing-quarto">Installing Quarto</h3>
});
clipboard.on('success', onCopySuccess);
if (window.document.getElementById('quarto-embedded-source-code-modal')) {
// For code content inside modals, clipBoardJS needs to be initialized with a container option
// TODO: Check when it could be a function (https://github.com/zenorocha/clipboard.js/issues/860)
const clipboardModal = new window.ClipboardJS('.code-copy-button[data-in-quarto-modal]', {
text: getTextToCopy,
container: window.document.getElementById('quarto-embedded-source-code-modal')
Expand Down Expand Up @@ -525,7 +523,6 @@ <h3 class="anchored" data-anchor-id="installing-quarto">Installing Quarto</h3>
if (window.Quarto?.typesetMath) {
window.Quarto.typesetMath(note);
}
// TODO in 1.5, we should make sure this works without a callout special case
if (note.classList.contains("callout")) {
return note.outerHTML;
} else {
Expand Down
79 changes: 38 additions & 41 deletions difference-in-differences.html

Large diffs are not rendered by default.

35 changes: 16 additions & 19 deletions marginaleffects.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head>

<meta charset="utf-8">
<meta name="generator" content="quarto-1.5.57">
<meta name="generator" content="quarto-1.6.37">

<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes">

Expand Down Expand Up @@ -69,10 +69,10 @@
<script src="site_libs/quarto-html/tippy.umd.min.js"></script>
<script src="site_libs/quarto-html/anchor.min.js"></script>
<link href="site_libs/quarto-html/tippy.css" rel="stylesheet">
<link href="site_libs/quarto-html/quarto-syntax-highlighting.css" rel="stylesheet" id="quarto-text-highlighting-styles">
<link href="site_libs/quarto-html/quarto-syntax-highlighting-29e2c20b02301cfff04dc8050bf30c7e.css" rel="stylesheet" id="quarto-text-highlighting-styles">
<script src="site_libs/bootstrap/bootstrap.min.js"></script>
<link href="site_libs/bootstrap/bootstrap-icons.css" rel="stylesheet">
<link href="site_libs/bootstrap/bootstrap.min.css" rel="stylesheet" id="quarto-bootstrap" data-mode="light">
<link href="site_libs/bootstrap/bootstrap-35b661c73272c531296c3b360bfb6fcf.min.css" rel="stylesheet" append-hash="true" id="quarto-bootstrap" data-mode="light">
<script id="quarto-search-options" type="application/json">{
"location": "navbar",
"copy-button": false,
Expand Down Expand Up @@ -252,7 +252,7 @@ <h1 class="title">Marginal Effects and Hypothesis Tests via <code>marginaleffect


<p>We can compute marginal effects and linear and non-linear hypothesis tests via the excellent <a href="https://github.com/vincentarelbundock/pymarginaleffects">marginaleffects</a> package.</p>
<div id="53f740c7" class="cell" data-execution_count="1">
<div id="e52a3dc8" class="cell" data-execution_count="1">
<div class="sourceCode cell-code" id="cb1"><pre class="sourceCode python code-with-copy"><code class="sourceCode python"><span id="cb1-1"><a href="#cb1-1" aria-hidden="true" tabindex="-1"></a><span class="im">from</span> marginaleffects <span class="im">import</span> hypotheses</span>
<span id="cb1-2"><a href="#cb1-2" aria-hidden="true" tabindex="-1"></a></span>
<span id="cb1-3"><a href="#cb1-3" aria-hidden="true" tabindex="-1"></a><span class="im">import</span> pyfixest <span class="im">as</span> pf</span>
Expand All @@ -263,7 +263,7 @@ <h1 class="title">Marginal Effects and Hypothesis Tests via <code>marginaleffect
<span id="cb1-8"><a href="#cb1-8" aria-hidden="true" tabindex="-1"></a>fit.tidy()</span></code><button title="Copy to Clipboard" class="code-copy-button"><i class="bi"></i></button></pre></div>
<div class="cell-output cell-output-display">

<div id="964YeS"></div>
<div id="34kYJd"></div>
<script type="text/javascript" data-lets-plot-script="library">
if(!window.letsPlotCallQueue) {
window.letsPlotCallQueue = [];
Expand All @@ -287,17 +287,17 @@ <h1 class="title">Marginal Effects and Hypothesis Tests via <code>marginaleffect
var div = document.createElement("div");
div.style.color = 'darkred';
div.textContent = 'Error loading Lets-Plot JS';
document.getElementById("964YeS").appendChild(div);
document.getElementById("34kYJd").appendChild(div);
};
var e = document.getElementById("964YeS");
var e = document.getElementById("34kYJd");
e.appendChild(script);
})()
</script>

</div>
<div class="cell-output cell-output-display">

<div id="B3WlHY"></div>
<div id="ZCOcrZ"></div>
<script type="text/javascript" data-lets-plot-script="library">
if(!window.letsPlotCallQueue) {
window.letsPlotCallQueue = [];
Expand All @@ -321,9 +321,9 @@ <h1 class="title">Marginal Effects and Hypothesis Tests via <code>marginaleffect
var div = document.createElement("div");
div.style.color = 'darkred';
div.textContent = 'Error loading Lets-Plot JS';
document.getElementById("B3WlHY").appendChild(div);
document.getElementById("ZCOcrZ").appendChild(div);
};
var e = document.getElementById("B3WlHY");
var e = document.getElementById("ZCOcrZ");
e.appendChild(script);
})()
</script>
Expand All @@ -344,7 +344,7 @@ <h1 class="title">Marginal Effects and Hypothesis Tests via <code>marginaleffect
<th data-quarto-table-cell-role="th">2.5%</th>
<th data-quarto-table-cell-role="th">97.5%</th>
</tr>
<tr class="odd">
<tr class="even">
<th data-quarto-table-cell-role="th">Coefficient</th>
<th data-quarto-table-cell-role="th"></th>
<th data-quarto-table-cell-role="th"></th>
Expand Down Expand Up @@ -390,7 +390,7 @@ <h1 class="title">Marginal Effects and Hypothesis Tests via <code>marginaleffect
</div>
<p>Suppose we were interested in testing the hypothesis that <span class="math inline">\(X_{1} = X_{2}\)</span>. Given the relatively large differences in coefficients and small standard errors, we will likely reject the null that the two parameters are equal.</p>
<p>We can run the formal test via the <code>hypotheses</code> function from the <code>marginaleffects</code> package.</p>
<div id="c8b7071f" class="cell" data-execution_count="2">
<div id="84c3f79d" class="cell" data-execution_count="2">
<div class="sourceCode cell-code" id="cb2"><pre class="sourceCode python code-with-copy"><code class="sourceCode python"><span id="cb2-1"><a href="#cb2-1" aria-hidden="true" tabindex="-1"></a>hypotheses(fit, <span class="st">"X1 - X2 = 0"</span>)</span></code><button title="Copy to Clipboard" class="code-copy-button"><i class="bi"></i></button></pre></div>
<div class="cell-output cell-output-display" data-execution_count="2">
<div><style>
Expand All @@ -413,7 +413,7 @@ <h1 class="title">Marginal Effects and Hypothesis Tests via <code>marginaleffect
<th data-quarto-table-cell-role="th">conf_low</th>
<th data-quarto-table-cell-role="th">conf_high</th>
</tr>
<tr class="odd">
<tr class="even">
<th>str</th>
<th>f64</th>
<th>f64</th>
Expand Down Expand Up @@ -446,7 +446,7 @@ <h2 class="anchored" data-anchor-id="non-linear-hypothesis-tests-ratio-estimates
<p>We can also test run-linear hypotheses, in which case <code>marginaleffects</code> will automatically compute correct standard errors based on the estimated covariance matrix and the Delta method. This is for example useful for computing inferential statistics for the “relative uplift” in an AB test.</p>
<p>For the moment, let’s assume that <span class="math inline">\(X1\)</span> is a randomly assigned treatment variable. As before, <span class="math inline">\(Y\)</span> is our variable / KPI of interest.</p>
<p>Under randomization, the model intercept measures the “baseline”, i.e.&nbsp;the population average of <span class="math inline">\(Y\)</span> in the absence of treatment. To compute a relative uplift, we might compute</p>
<div id="fc0aab3e" class="cell" data-execution_count="3">
<div id="d672f3cf" class="cell" data-execution_count="3">
<div class="sourceCode cell-code" id="cb3"><pre class="sourceCode python code-with-copy"><code class="sourceCode python"><span id="cb3-1"><a href="#cb3-1" aria-hidden="true" tabindex="-1"></a>(fit.coef().xs(<span class="st">"X1"</span>) <span class="op">/</span> fit.coef().xs(<span class="st">"Intercept"</span>) <span class="op">-</span> <span class="dv">1</span>) <span class="op">*</span> <span class="dv">100</span></span></code><button title="Copy to Clipboard" class="code-copy-button"><i class="bi"></i></button></pre></div>
<div class="cell-output cell-output-display" data-execution_count="3">
<pre><code>np.float64(-211.71906665561212)</code></pre>
Expand All @@ -473,7 +473,7 @@ <h3 class="anchored" data-anchor-id="the-multivariate-delta-method">The Multivar
<section id="using-the-delta-method-via-marginaleffects" class="level3">
<h3 class="anchored" data-anchor-id="using-the-delta-method-via-marginaleffects">Using the Delta Method via <code>marginaleffects</code>:</h3>
<p>We can employ the Delta Method via <code>marginaleffects</code> via the <code>hypotheses</code> function:</p>
<div id="b7e7daa5" class="cell" data-execution_count="4">
<div id="5248790d" class="cell" data-execution_count="4">
<div class="sourceCode cell-code" id="cb5"><pre class="sourceCode python code-with-copy"><code class="sourceCode python"><span id="cb5-1"><a href="#cb5-1" aria-hidden="true" tabindex="-1"></a>hypotheses(fit, <span class="st">"(X1 / Intercept - 1) * 100 = 0"</span>)</span></code><button title="Copy to Clipboard" class="code-copy-button"><i class="bi"></i></button></pre></div>
<div class="cell-output cell-output-display" data-execution_count="4">
<div><style>
Expand All @@ -496,7 +496,7 @@ <h3 class="anchored" data-anchor-id="using-the-delta-method-via-marginaleffects"
<th data-quarto-table-cell-role="th">conf_low</th>
<th data-quarto-table-cell-role="th">conf_high</th>
</tr>
<tr class="odd">
<tr class="even">
<th>str</th>
<th>f64</th>
<th>f64</th>
Expand Down Expand Up @@ -613,8 +613,6 @@ <h3 class="anchored" data-anchor-id="using-the-delta-method-via-marginaleffects"
});
clipboard.on('success', onCopySuccess);
if (window.document.getElementById('quarto-embedded-source-code-modal')) {
// For code content inside modals, clipBoardJS needs to be initialized with a container option
// TODO: Check when it could be a function (https://github.com/zenorocha/clipboard.js/issues/860)
const clipboardModal = new window.ClipboardJS('.code-copy-button[data-in-quarto-modal]', {
text: getTextToCopy,
container: window.document.getElementById('quarto-embedded-source-code-modal')
Expand Down Expand Up @@ -725,7 +723,6 @@ <h3 class="anchored" data-anchor-id="using-the-delta-method-via-marginaleffects"
if (window.Quarto?.typesetMath) {
window.Quarto.typesetMath(note);
}
// TODO in 1.5, we should make sure this works without a callout special case
if (note.classList.contains("callout")) {
return note.outerHTML;
} else {
Expand Down
11 changes: 4 additions & 7 deletions pyfixest.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head>

<meta charset="utf-8">
<meta name="generator" content="quarto-1.5.57">
<meta name="generator" content="quarto-1.6.37">

<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes">

Expand Down Expand Up @@ -69,10 +69,10 @@
<script src="site_libs/quarto-html/tippy.umd.min.js"></script>
<script src="site_libs/quarto-html/anchor.min.js"></script>
<link href="site_libs/quarto-html/tippy.css" rel="stylesheet">
<link href="site_libs/quarto-html/quarto-syntax-highlighting.css" rel="stylesheet" id="quarto-text-highlighting-styles">
<link href="site_libs/quarto-html/quarto-syntax-highlighting-29e2c20b02301cfff04dc8050bf30c7e.css" rel="stylesheet" id="quarto-text-highlighting-styles">
<script src="site_libs/bootstrap/bootstrap.min.js"></script>
<link href="site_libs/bootstrap/bootstrap-icons.css" rel="stylesheet">
<link href="site_libs/bootstrap/bootstrap.min.css" rel="stylesheet" id="quarto-bootstrap" data-mode="light">
<link href="site_libs/bootstrap/bootstrap-35b661c73272c531296c3b360bfb6fcf.min.css" rel="stylesheet" append-hash="true" id="quarto-bootstrap" data-mode="light">
<script id="quarto-search-options" type="application/json">{
"location": "navbar",
"copy-button": false,
Expand Down Expand Up @@ -183,7 +183,7 @@
<!-- margin-sidebar -->

<!-- main -->
<main class="content" id="quarto-document-content">
<main class="content" id="quarto-document-content"><header id="title-block-header" class="quarto-title-block"></header>



Expand Down Expand Up @@ -457,8 +457,6 @@ <h2 class="anchored" data-anchor-id="contributors">Contributors ✨</h2>
});
clipboard.on('success', onCopySuccess);
if (window.document.getElementById('quarto-embedded-source-code-modal')) {
// For code content inside modals, clipBoardJS needs to be initialized with a container option
// TODO: Check when it could be a function (https://github.com/zenorocha/clipboard.js/issues/860)
const clipboardModal = new window.ClipboardJS('.code-copy-button[data-in-quarto-modal]', {
text: getTextToCopy,
container: window.document.getElementById('quarto-embedded-source-code-modal')
Expand Down Expand Up @@ -569,7 +567,6 @@ <h2 class="anchored" data-anchor-id="contributors">Contributors ✨</h2>
if (window.Quarto?.typesetMath) {
window.Quarto.typesetMath(note);
}
// TODO in 1.5, we should make sure this works without a callout special case
if (note.classList.contains("callout")) {
return note.outerHTML;
} else {
Expand Down
Binary file modified quarto_example/QuartoExample.pdf
Binary file not shown.
Loading

0 comments on commit dde54b3

Please sign in to comment.