Skip to content

Commit

Permalink
Deploying to gh-pages from @ bf29c2a 🚀
Browse files Browse the repository at this point in the history
  • Loading branch information
yh202109 committed Jul 22, 2024
1 parent fabcc81 commit 03b04be
Show file tree
Hide file tree
Showing 16 changed files with 209 additions and 215 deletions.
4 changes: 2 additions & 2 deletions _downloads/214d05cd65dcc9387b037da1ce5a5c33/report.html

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion _downloads/9911a4d807ac9f1a695f0aa2cf687076/coverage.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" ?>
<coverage version="7.6.0" timestamp="1721606483319" lines-valid="1494" lines-covered="642" line-rate="0.4297" branches-covered="0" branches-valid="0" branch-rate="0" complexity="0">
<coverage version="7.6.0" timestamp="1721615960831" lines-valid="1494" lines-covered="642" line-rate="0.4297" branches-covered="0" branches-valid="0" branch-rate="0" complexity="0">
<!-- Generated by coverage.py: https://coverage.readthedocs.io/en/7.6.0 -->
<!-- Based on https://raw.githubusercontent.com/cobertura/web/master/htdocs/xml/coverage-04.dtd -->
<sources>
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
21 changes: 11 additions & 10 deletions _sources/statlab_kappa2.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -251,13 +251,14 @@ probability of having agreement for a sample from two randomly selected raters e
:eq:`eq_exp1` corresponds to the expected
probability of having agreement for a sample from two randomly selected raters under the assumption of no agreement,
which corresponds to the assumption of :math:`(N_{i1},\ldots, N_{iJ}) \sim multi(R, (p_1,\ldots, p_J))` where :math:`R>4`.
Note that the notations in this page did not use conventional 'hat' to represent estimated :math:`p_j`.


Let :math:`S_{p2} = \sum_j p_j^2`, :math:`S_{p3} = \sum_j p_j^3`, and :math:`S_{p4} = \sum_j p_j^4`.
The equation :eq:`eq_kappa1` can be expressed as [2]_ :sup:`(Eq. 9)`,

.. math::
\kappa = \frac{\sum_{i=1}^{n}\sum_{j=1}^J N_{ij}^2 - nR\left(1+(R-1)\sum_{j=1}^J p_j^2\right)}{nR(R-1)(1-\sum_{j=1}^J p_j^2)}
\kappa = \frac{\sum_{i=1}^{n}\sum_{j=1}^J N_{ij}^2 - nR\left(1+(R-1) S_{p2} \right)}{nR(R-1)(1- S_{p2} )}
Note that Fleiss (1971) assumed large :math:`n` and fixed :math:`p_j` while deriving variance of kappa.
Expand All @@ -272,7 +273,7 @@ where

.. math::
c(n,R,\{p_j\}) = n^{-1}\left(R(R-1)\left(1-\sum_{j=1}^J p_j^2\right)\right)^{-2},
c(n,R,\{p_j\}) = n^{-1}\left(R(R-1)\left(1-S_{p2}\right)\right)^{-2},
and

Expand All @@ -294,16 +295,16 @@ The first element of :eq:`eq_kappa2_vn2` can be calculated as [2]_ :sup:`(Eq. 12
:label: eq_kappa2_vn3
E\left(\sum_{j} N_{ij}^4\right)
= R + 7R(R-1)\sum_j p_j^2 + 6R(R-1)(R-2)\sum_j p_j^3 + R(R-1)(R-2)(R-3)\sum_j p_j^4
= R + 7R(R-1)S_{p2} + 6R(R-1)(R-2)S_{p3} + R(R-1)(R-2)(R-3)S_{p4}
The third element of :eq:`eq_kappa2_vn2` can be calculated as [2]_ :sup:`(Eq. 14)`

.. math::
:label: eq_kappa2_vn4
\left(E\left(\sum_{j} N_{ij}^2\right)\right)^2
=& R^2\left(1 + (R-1)\sum_{j} p_j^2 \right)^2 \\
=& R^2 + R^2(R-1)\left(2\sum_{j} p_j^2 + (R-1)(\sum_j p_j^2)^2\right)
=& R^2\left(1 + (R-1)S_{p2} \right)^2 \\
=& R^2 + R^2(R-1)\left(2 S_{p2} + (R-1)S_{p2}^2\right)
The second element of :eq:`eq_kappa2_vn2` can be calculated, using
:math:`E\left( N_{ij}^2 N_{ik}^2 \right) = R(R-1)p_j(p_k+(R-2)p_k^2) + R(R-1)(R-2)p_j^2(p_k+(R-3)p_k^2)`, as
Expand All @@ -312,17 +313,17 @@ The second element of :eq:`eq_kappa2_vn2` can be calculated, using
:label: eq_kappa2_vn5
E\left( \sum_j\sum_{k \neq j} N_{ij}^2 N_{ik}^2 \right)
=& R(R-1) + R(R-1)(2R-5)\left(\sum_j p_j^2\right)
- 2R(R-1)(R-2)\left(\sum_j p_j^3\right) \\
&- R(R-1)(R-2)(R-3)\left(\sum_j p_j^4 \right) + R(R-1)(R-2)(R-3) \left(\sum_{j} p_j^2\right)^2
=& R(R-1) + R(R-1)(2R-5)S_{p2}
- 2R(R-1)(R-2)S_{p3} \\
&- R(R-1)(R-2)(R-3)S_{p4} + R(R-1)(R-2)(R-3) S_{p2}^2
Combining :eq:`eq_kappa2_vn3`, :eq:`eq_kappa2_vn4`, and :eq:`eq_kappa2_vn5`,
:eq:`eq_kappa2_vn2` can be calculated as [2]_ :sup:`(Eq. 15)`

.. math::
var\left(\sum_{j} N_{ij}^2 \right)
= 2R(R-1)\left(\sum_j p_j^2 - (2R-3)\left(\sum_j p_j^2\right)^2 + 2(R-2)\sum_j p_j^3\right).
= 2R(R-1)\left(S_{p2} - (2R-3)S_{p2}^2 + 2(R-2)S_{p3}\right).
*************
Lab Exercise
Expand Down
2 changes: 1 addition & 1 deletion _static/reports/coverage/coverage.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" ?>
<coverage version="7.6.0" timestamp="1721606483319" lines-valid="1494" lines-covered="642" line-rate="0.4297" branches-covered="0" branches-valid="0" branch-rate="0" complexity="0">
<coverage version="7.6.0" timestamp="1721615960831" lines-valid="1494" lines-covered="642" line-rate="0.4297" branches-covered="0" branches-valid="0" branch-rate="0" complexity="0">
<!-- Generated by coverage.py: https://coverage.readthedocs.io/en/7.6.0 -->
<!-- Based on https://raw.githubusercontent.com/cobertura/web/master/htdocs/xml/coverage-04.dtd -->
<sources>
Expand Down
2 changes: 1 addition & 1 deletion _static/reports/junit/junit.xml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<?xml version="1.0" encoding="utf-8"?><testsuites><testsuite name="pytest" errors="0" failures="0" skipped="0" tests="38" time="8.845" timestamp="2024-07-22T00:01:04.705295+00:00" hostname="fv-az1242-959"><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_1df_invalid_input" time="0.002" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_1df_missing_column" time="0.001" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_1df_with_difference" time="0.005" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_1df_without_difference" time="0.002" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_2df_with_existing_column" time="0.010" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_2df_with_non_existing_column" time="0.001" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_2df_with_non_existing_group" time="0.001" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_2df_with_same_group_and_column" time="0.001" /><testcase classname="tests.test_health_ectd.TestCtocByFDA" name="test_find_section_given_words" time="0.001" /><testcase classname="tests.test_health_ectd.TestCtocByFDA" name="test_find_section_given_words_invalid_include" time="0.001" /><testcase classname="tests.test_health_ectd.TestCtocByFDA" name="test_find_section_given_words_invalid_outfmt" time="0.001" /><testcase classname="tests.test_health_ectd.TestCtocByFDA" name="test_load_list" time="0.001" /><testcase classname="tests.test_health_ectd.TestCtocByFDA" name="test_show_ctoc_tree" time="0.199" /><testcase classname="tests.test_health_emt.TestEmt" name="test_expected_file_lists" time="0.005" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_files" time="0.005" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_hlgt" time="0.004" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_hlt" time="0.004" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_llt" time="0.008" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_pt" time="0.004" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_pt_given_soc" time="0.006" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_pt_given_soc_primary_only" time="0.007" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_soc" time="0.004" /><testcase classname="tests.test_health_emt.TestEmt" name="test_list_files" time="0.026" /><testcase classname="tests.test_lsr.TestLsrTree" name="test_list_files_dataframe" time="0.001" /><testcase classname="tests.test_lsr.TestLsrTree" name="test_list_files_json" time="0.001" /><testcase classname="tests.test_lsr.TestLsrTree" name="test_list_files_list" time="0.000" /><testcase classname="tests.test_lsr.TestLsrTree" name="test_list_files_string" time="0.000" /><testcase classname="tests.test_lsr.TestLsrTree" name="test_list_files_tree" time="0.014" /><testcase classname="tests.test_lsr.TestLsrTree" name="test_list_files_tree2" time="0.009" /><testcase classname="tests.test_statlab_corr.TestCorrCalculator" name="test_calculate_kendall_tau_with_dataframe" time="0.002" /><testcase classname="tests.test_statlab_corr.TestCorrCalculator" name="test_calculate_kendall_tau_with_list" time="0.002" /><testcase classname="tests.test_statlab_corr.TestCorrCalculator" name="test_plot_y_list" time="0.018" /><testcase classname="tests.test_statlab_kappa.TestKappaCalculator" name="test_bootstrap_cohen_ci" time="0.231" /><testcase classname="tests.test_statlab_kappa.TestKappaCalculator" name="test_cohen" time="0.070" /><testcase classname="tests.test_statlab_kappa.TestKappaCalculator" name="test_fleiss_kappa" time="0.072" /><testcase classname="tests.test_stdiso_pdfsummary.TestPdfSummary" name="test_compare_file_size" time="0.768" /><testcase classname="tests.test_stdiso_pdfsummary.TestPdfSummary" name="test_get_outline_list" time="0.896" /><testcase classname="tests.test_stdiso_pdfsummary.TestPdfSummary" name="test_show_outline_tree" time="0.842" /></testsuite></testsuites>
<?xml version="1.0" encoding="utf-8"?><testsuites><testsuite name="pytest" errors="0" failures="0" skipped="0" tests="38" time="10.153" timestamp="2024-07-22T02:39:01.134941+00:00" hostname="fv-az1121-390"><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_1df_invalid_input" time="0.002" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_1df_missing_column" time="0.001" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_1df_with_difference" time="0.005" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_1df_without_difference" time="0.002" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_2df_with_existing_column" time="0.010" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_2df_with_non_existing_column" time="0.001" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_2df_with_non_existing_group" time="0.001" /><testcase classname="tests.test_cdt.TestCdt" name="test_diff_2cols_in_2df_with_same_group_and_column" time="0.001" /><testcase classname="tests.test_health_ectd.TestCtocByFDA" name="test_find_section_given_words" time="0.001" /><testcase classname="tests.test_health_ectd.TestCtocByFDA" name="test_find_section_given_words_invalid_include" time="0.001" /><testcase classname="tests.test_health_ectd.TestCtocByFDA" name="test_find_section_given_words_invalid_outfmt" time="0.001" /><testcase classname="tests.test_health_ectd.TestCtocByFDA" name="test_load_list" time="0.001" /><testcase classname="tests.test_health_ectd.TestCtocByFDA" name="test_show_ctoc_tree" time="0.199" /><testcase classname="tests.test_health_emt.TestEmt" name="test_expected_file_lists" time="0.004" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_files" time="0.005" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_hlgt" time="0.004" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_hlt" time="0.004" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_llt" time="0.007" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_pt" time="0.004" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_pt_given_soc" time="0.006" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_pt_given_soc_primary_only" time="0.006" /><testcase classname="tests.test_health_emt.TestEmt" name="test_find_soc" time="0.004" /><testcase classname="tests.test_health_emt.TestEmt" name="test_list_files" time="0.025" /><testcase classname="tests.test_lsr.TestLsrTree" name="test_list_files_dataframe" time="0.001" /><testcase classname="tests.test_lsr.TestLsrTree" name="test_list_files_json" time="0.001" /><testcase classname="tests.test_lsr.TestLsrTree" name="test_list_files_list" time="0.001" /><testcase classname="tests.test_lsr.TestLsrTree" name="test_list_files_string" time="0.000" /><testcase classname="tests.test_lsr.TestLsrTree" name="test_list_files_tree" time="0.013" /><testcase classname="tests.test_lsr.TestLsrTree" name="test_list_files_tree2" time="0.008" /><testcase classname="tests.test_statlab_corr.TestCorrCalculator" name="test_calculate_kendall_tau_with_dataframe" time="0.002" /><testcase classname="tests.test_statlab_corr.TestCorrCalculator" name="test_calculate_kendall_tau_with_list" time="0.002" /><testcase classname="tests.test_statlab_corr.TestCorrCalculator" name="test_plot_y_list" time="0.017" /><testcase classname="tests.test_statlab_kappa.TestKappaCalculator" name="test_bootstrap_cohen_ci" time="0.227" /><testcase classname="tests.test_statlab_kappa.TestKappaCalculator" name="test_cohen" time="0.067" /><testcase classname="tests.test_statlab_kappa.TestKappaCalculator" name="test_fleiss_kappa" time="0.065" /><testcase classname="tests.test_stdiso_pdfsummary.TestPdfSummary" name="test_compare_file_size" time="0.754" /><testcase classname="tests.test_stdiso_pdfsummary.TestPdfSummary" name="test_get_outline_list" time="0.845" /><testcase classname="tests.test_stdiso_pdfsummary.TestPdfSummary" name="test_show_outline_tree" time="0.828" /></testsuite></testsuites>
4 changes: 2 additions & 2 deletions _static/reports/junit/report.html

Large diffs are not rendered by default.

10 changes: 3 additions & 7 deletions example_cdtg.html
Original file line number Diff line number Diff line change
Expand Up @@ -133,15 +133,11 @@ <h1>U/Graph/Categorical Plots Using catPlotter<a class="headerlink" href="#u-gra
</div>
</div>
<div class="cell_output docutils container">
<div class="output stderr highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>/home/runner/.cache/pypoetry/virtualenvs/mtbp3-STzYEG9e-py3.10/lib/python3.10/site-packages/seaborn/categorical.py:3399: UserWarning: 11.1% of the points cannot be placed; you may want to decrease the size of the markers or use stripplot.
warnings.warn(msg, UserWarning)
/home/runner/.cache/pypoetry/virtualenvs/mtbp3-STzYEG9e-py3.10/lib/python3.10/site-packages/seaborn/categorical.py:3399: UserWarning: 25.0% of the points cannot be placed; you may want to decrease the size of the markers or use stripplot.
warnings.warn(msg, UserWarning)
/home/runner/.cache/pypoetry/virtualenvs/mtbp3-STzYEG9e-py3.10/lib/python3.10/site-packages/seaborn/categorical.py:3399: UserWarning: 30.0% of the points cannot be placed; you may want to decrease the size of the markers or use stripplot.
<div class="output stderr highlight-myst-ansi notranslate"><div class="highlight"><pre><span></span>/home/runner/.cache/pypoetry/virtualenvs/mtbp3-STzYEG9e-py3.10/lib/python3.10/site-packages/seaborn/categorical.py:3399: UserWarning: 35.0% of the points cannot be placed; you may want to decrease the size of the markers or use stripplot.
warnings.warn(msg, UserWarning)
</pre></div>
</div>
<img alt="_images/b48368b32682c4cc9ab6249c62eef7d29bd38d3e5a903ca07b6c911f1f2a03f5.png" src="_images/b48368b32682c4cc9ab6249c62eef7d29bd38d3e5a903ca07b6c911f1f2a03f5.png" />
<img alt="_images/82f878b8d8450009ea9f3b8434afd4a147fa4501db9f66766beaffc03493b60c.png" src="_images/82f878b8d8450009ea9f3b8434afd4a147fa4501db9f66766beaffc03493b60c.png" />
</div>
</div>
<p>To create a line plot:</p>
Expand All @@ -153,7 +149,7 @@ <h1>U/Graph/Categorical Plots Using catPlotter<a class="headerlink" href="#u-gra
</div>
</div>
<div class="cell_output docutils container">
<img alt="_images/cfddb32ab3f2294e749768f3ba9bf366367e88e301af8cde289f5acf8720780c.png" src="_images/cfddb32ab3f2294e749768f3ba9bf366367e88e301af8cde289f5acf8720780c.png" />
<img alt="_images/4cd44a2a004d681aab3cbb72afe7536c2407426ef57d7ab86175e399660b4e56.png" src="_images/4cd44a2a004d681aab3cbb72afe7536c2407426ef57d7ab86175e399660b4e56.png" />
</div>
</div>
</section>
Expand Down
Loading

0 comments on commit 03b04be

Please sign in to comment.