Skip to content

Commit

Permalink
deploy: c06e5ba
Browse files Browse the repository at this point in the history
  • Loading branch information
spring-haru committed Jul 21, 2024
1 parent fb00928 commit f0e265e
Show file tree
Hide file tree
Showing 151 changed files with 379 additions and 366 deletions.
66 changes: 33 additions & 33 deletions 10_Residuals.html

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions 11_Inference.html
Original file line number Diff line number Diff line change
Expand Up @@ -480,9 +480,9 @@ <h1>推論<a class="headerlink" href="#id1" title="Link to this heading">#</a></
<div class="highlight-ipython3 notranslate"><div class="highlight"><pre><span></span><span class="kn">import</span> <span class="nn">matplotlib.pyplot</span> <span class="k">as</span> <span class="nn">plt</span>
<span class="kn">import</span> <span class="nn">numpy</span> <span class="k">as</span> <span class="nn">np</span>
<span class="kn">import</span> <span class="nn">pandas</span> <span class="k">as</span> <span class="nn">pd</span>
<span class="kn">import</span> <span class="nn">statsmodels.formula.api</span> <span class="k">as</span> <span class="nn">smf</span>
<span class="kn">import</span> <span class="nn">wooldridge</span>

<span class="kn">from</span> <span class="nn">statsmodels.formula.api</span> <span class="kn">import</span> <span class="n">ols</span>
<span class="kn">from</span> <span class="nn">scipy.stats</span> <span class="kn">import</span> <span class="n">t</span><span class="p">,</span> <span class="n">f</span>

<span class="c1"># 警告メッセージを非表示</span>
Expand Down Expand Up @@ -833,7 +833,7 @@ <h3>回帰分析と<span class="math notranslate nohighlight">\(t\)</span>検定
<div class="cell docutils container">
<div class="cell_input docutils container">
<div class="highlight-ipython3 notranslate"><div class="highlight"><pre><span></span><span class="n">formula_gpa</span> <span class="o">=</span> <span class="s1">&#39;colGPA ~ hsGPA + ACT + skipped&#39;</span>
<span class="n">res_gpa</span> <span class="o">=</span> <span class="n">ols</span><span class="p">(</span><span class="n">formula_gpa</span><span class="p">,</span> <span class="n">data</span><span class="o">=</span><span class="n">gpa</span><span class="p">)</span><span class="o">.</span><span class="n">fit</span><span class="p">()</span>
<span class="n">res_gpa</span> <span class="o">=</span> <span class="n">smf</span><span class="o">.</span><span class="n">ols</span><span class="p">(</span><span class="n">formula_gpa</span><span class="p">,</span> <span class="n">data</span><span class="o">=</span><span class="n">gpa</span><span class="p">)</span><span class="o">.</span><span class="n">fit</span><span class="p">()</span>
</pre></div>
</div>
</div>
Expand Down Expand Up @@ -1211,7 +1211,7 @@ <h3>回帰分析<a class="headerlink" href="#id10" title="Link to this heading">
<div class="cell docutils container">
<div class="cell_input docutils container">
<div class="highlight-ipython3 notranslate"><div class="highlight"><pre><span></span><span class="n">formula_0</span> <span class="o">=</span> <span class="s1">&#39;np.log(salary) ~ years + gamesyr + bavg + hrunsyr + rbisyr&#39;</span>
<span class="n">res_0</span> <span class="o">=</span> <span class="n">ols</span><span class="p">(</span><span class="n">formula_0</span><span class="p">,</span> <span class="n">data</span><span class="o">=</span><span class="n">mlb1</span><span class="p">)</span><span class="o">.</span><span class="n">fit</span><span class="p">()</span>
<span class="n">res_0</span> <span class="o">=</span> <span class="n">smf</span><span class="o">.</span><span class="n">ols</span><span class="p">(</span><span class="n">formula_0</span><span class="p">,</span> <span class="n">data</span><span class="o">=</span><span class="n">mlb1</span><span class="p">)</span><span class="o">.</span><span class="n">fit</span><span class="p">()</span>
</pre></div>
</div>
</div>
Expand All @@ -1226,7 +1226,7 @@ <h4>例1<a class="headerlink" href="#id11" title="Link to this heading">#</a><
<div class="cell docutils container">
<div class="cell_input docutils container">
<div class="highlight-ipython3 notranslate"><div class="highlight"><pre><span></span><span class="n">formula_1</span> <span class="o">=</span> <span class="s1">&#39;np.log(salary) ~ years + gamesyr&#39;</span>
<span class="n">res_1</span> <span class="o">=</span> <span class="n">ols</span><span class="p">(</span><span class="n">formula_1</span><span class="p">,</span> <span class="n">data</span><span class="o">=</span><span class="n">mlb1</span><span class="p">)</span><span class="o">.</span><span class="n">fit</span><span class="p">()</span>
<span class="n">res_1</span> <span class="o">=</span> <span class="n">smf</span><span class="o">.</span><span class="n">ols</span><span class="p">(</span><span class="n">formula_1</span><span class="p">,</span> <span class="n">data</span><span class="o">=</span><span class="n">mlb1</span><span class="p">)</span><span class="o">.</span><span class="n">fit</span><span class="p">()</span>
</pre></div>
</div>
</div>
Expand Down Expand Up @@ -1371,8 +1371,8 @@ <h4>例2<a class="headerlink" href="#id14" title="Link to this heading">#</a><
Dep. Variable: np.log(salary) R-squared: 0.628
Model: OLS Adj. R-squared: 0.622
Method: Least Squares F-statistic: 117.1
Date: Sat, 20 Jul 2024 Prob (F-statistic): 2.94e-72
Time: 04:39:41 Log-Likelihood: -385.11
Date: Sun, 21 Jul 2024 Prob (F-statistic): 2.94e-72
Time: 05:16:44 Log-Likelihood: -385.11
No. Observations: 353 AIC: 782.2
Df Residuals: 347 BIC: 805.4
Df Model: 5
Expand Down
Loading

0 comments on commit f0e265e

Please sign in to comment.