pystatsbio 4.0.2__tar.gz → 4.0.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (193) hide show
  1. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/CHANGELOG.md +20 -0
  2. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/PKG-INFO +3 -3
  3. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/README.md +1 -1
  4. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pyproject.toml +5 -4
  5. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/__init__.py +1 -1
  6. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/pk/_nca.py +30 -24
  7. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/.github/workflows/publish.yml +0 -0
  8. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/.github/workflows/trigger-docs-rebuild.yml +0 -0
  9. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/.gitignore +0 -0
  10. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/.release/CHECKLIST.md +0 -0
  11. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/.release/UNRELEASED.md +0 -0
  12. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/.release/release.py +0 -0
  13. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/LICENSE +0 -0
  14. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/Forge.md +0 -0
  15. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/GPU_BACKEND_NOTES.md +0 -0
  16. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/Makefile +0 -0
  17. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/PROGRESS.md +0 -0
  18. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/PYSTATSBIO_CONTEXT.md +0 -0
  19. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/Powerhouse.md +0 -0
  20. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/SGC_BIO_DIRECTIVE.md +0 -0
  21. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/SGC_CORE_DIRECTIVE.md +0 -0
  22. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/.buildinfo +0 -0
  23. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/.doctrees/__intersphinx_cache__/numpy_objects.inv +0 -0
  24. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/.doctrees/__intersphinx_cache__/python_objects.inv +0 -0
  25. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/.doctrees/__intersphinx_cache__/scipy_objects.inv +0 -0
  26. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/.doctrees/diagnostic.doctree +0 -0
  27. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/.doctrees/doseresponse.doctree +0 -0
  28. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/.doctrees/environment.pickle +0 -0
  29. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/.doctrees/index.doctree +0 -0
  30. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/.doctrees/pk.doctree +0 -0
  31. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/.doctrees/power.doctree +0 -0
  32. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/index.html +0 -0
  33. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/diagnostic/_accuracy.html +0 -0
  34. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/diagnostic/_batch.html +0 -0
  35. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/diagnostic/_common.html +0 -0
  36. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/diagnostic/_cutoff.html +0 -0
  37. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/diagnostic/_roc.html +0 -0
  38. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/doseresponse/_batch.html +0 -0
  39. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/doseresponse/_bmd.html +0 -0
  40. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/doseresponse/_common.html +0 -0
  41. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/doseresponse/_fit.html +0 -0
  42. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/doseresponse/_models.html +0 -0
  43. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/doseresponse/_potency.html +0 -0
  44. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/pk/_common.html +0 -0
  45. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/pk/_nca.html +0 -0
  46. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/power/_anova.html +0 -0
  47. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/power/_cluster.html +0 -0
  48. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/power/_common.html +0 -0
  49. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/power/_crossover.html +0 -0
  50. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/power/_means.html +0 -0
  51. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/power/_noninferiority.html +0 -0
  52. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/power/_proportions.html +0 -0
  53. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_modules/pystatsbio/power/_survival.html +0 -0
  54. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_sources/diagnostic.rst.txt +0 -0
  55. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_sources/doseresponse.rst.txt +0 -0
  56. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_sources/index.rst.txt +0 -0
  57. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_sources/pk.rst.txt +0 -0
  58. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_sources/power.rst.txt +0 -0
  59. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/base-stemmer.js +0 -0
  60. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/basic.css +0 -0
  61. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/custom.css +0 -0
  62. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/debug.css +0 -0
  63. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/doctools.js +0 -0
  64. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/documentation_options.js +0 -0
  65. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/english-stemmer.js +0 -0
  66. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/file.png +0 -0
  67. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/language_data.js +0 -0
  68. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/minus.png +0 -0
  69. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/plus.png +0 -0
  70. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/pygments.css +0 -0
  71. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/scripts/furo-extensions.js +0 -0
  72. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/scripts/furo.js +0 -0
  73. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/scripts/furo.js.LICENSE.txt +0 -0
  74. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/scripts/furo.js.map +0 -0
  75. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/searchtools.js +0 -0
  76. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/skeleton.css +0 -0
  77. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/sphinx_highlight.js +0 -0
  78. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/styles/furo-extensions.css +0 -0
  79. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/styles/furo-extensions.css.map +0 -0
  80. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/styles/furo.css +0 -0
  81. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/_static/styles/furo.css.map +0 -0
  82. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/diagnostic.html +0 -0
  83. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/doseresponse.html +0 -0
  84. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/genindex.html +0 -0
  85. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/index.html +0 -0
  86. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/objects.inv +0 -0
  87. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/pk.html +0 -0
  88. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/power.html +0 -0
  89. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/py-modindex.html +0 -0
  90. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/search.html +0 -0
  91. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_build/html/searchindex.js +0 -0
  92. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/_static/custom.css +0 -0
  93. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/conf.py +0 -0
  94. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/diagnostic.rst +0 -0
  95. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/doseresponse.rst +0 -0
  96. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/epi.rst +0 -0
  97. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/gee.rst +0 -0
  98. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/index.rst +0 -0
  99. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/meta.rst +0 -0
  100. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/pk.rst +0 -0
  101. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/docs/power.rst +0 -0
  102. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/CONVENTIONS.md +0 -0
  103. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/diagnostic/__init__.py +0 -0
  104. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/diagnostic/_accuracy.py +0 -0
  105. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/diagnostic/_batch.py +0 -0
  106. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/diagnostic/_common.py +0 -0
  107. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/diagnostic/_cutoff.py +0 -0
  108. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/diagnostic/_roc.py +0 -0
  109. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/doseresponse/__init__.py +0 -0
  110. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/doseresponse/_batch.py +0 -0
  111. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/doseresponse/_bmd.py +0 -0
  112. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/doseresponse/_common.py +0 -0
  113. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/doseresponse/_fit.py +0 -0
  114. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/doseresponse/_models.py +0 -0
  115. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/doseresponse/_potency.py +0 -0
  116. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/epi/__init__.py +0 -0
  117. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/epi/_common.py +0 -0
  118. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/epi/_mantel_haenszel.py +0 -0
  119. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/epi/_measures.py +0 -0
  120. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/epi/_standardize.py +0 -0
  121. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/gee/__init__.py +0 -0
  122. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/gee/_common.py +0 -0
  123. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/gee/_correlation.py +0 -0
  124. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/gee/_estimating_equations.py +0 -0
  125. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/gee/_sandwich.py +0 -0
  126. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/gee/backends/__init__.py +0 -0
  127. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/gee/backends/_gpu_correlation.py +0 -0
  128. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/gee/backends/_gpu_family.py +0 -0
  129. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/gee/backends/gpu_fit.py +0 -0
  130. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/meta/__init__.py +0 -0
  131. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/meta/_common.py +0 -0
  132. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/meta/_fixed.py +0 -0
  133. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/meta/_heterogeneity.py +0 -0
  134. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/meta/_random.py +0 -0
  135. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/pk/__init__.py +0 -0
  136. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/pk/_common.py +0 -0
  137. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/power/__init__.py +0 -0
  138. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/power/_anova.py +0 -0
  139. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/power/_cluster.py +0 -0
  140. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/power/_common.py +0 -0
  141. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/power/_crossover.py +0 -0
  142. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/power/_means.py +0 -0
  143. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/power/_noninferiority.py +0 -0
  144. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/power/_proportions.py +0 -0
  145. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/power/_survival.py +0 -0
  146. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/pystatsbio/py.typed +0 -0
  147. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/__init__.py +0 -0
  148. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/diagnostic/__init__.py +0 -0
  149. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/diagnostic/test_accuracy.py +0 -0
  150. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/diagnostic/test_batch.py +0 -0
  151. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/diagnostic/test_common.py +0 -0
  152. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/diagnostic/test_cutoff.py +0 -0
  153. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/diagnostic/test_roc.py +0 -0
  154. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/diagnostic/test_roc_test.py +0 -0
  155. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/doseresponse/__init__.py +0 -0
  156. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/doseresponse/test_batch.py +0 -0
  157. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/doseresponse/test_bmd.py +0 -0
  158. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/doseresponse/test_common.py +0 -0
  159. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/doseresponse/test_fit.py +0 -0
  160. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/doseresponse/test_models.py +0 -0
  161. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/doseresponse/test_potency.py +0 -0
  162. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/doseresponse/test_ryegrass_drc.py +0 -0
  163. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/epi/__init__.py +0 -0
  164. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/epi/test_epi.py +0 -0
  165. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/gee/__init__.py +0 -0
  166. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/gee/test_gee.py +0 -0
  167. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/meta/__init__.py +0 -0
  168. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/meta/test_meta.py +0 -0
  169. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/meta/test_metafor_bcg.py +0 -0
  170. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/pk/__init__.py +0 -0
  171. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/pk/test_ars_lambda_z.py +0 -0
  172. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/pk/test_common.py +0 -0
  173. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/pk/test_nca.py +0 -0
  174. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/power/__init__.py +0 -0
  175. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/power/test_anova.py +0 -0
  176. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/power/test_cluster.py +0 -0
  177. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/power/test_common.py +0 -0
  178. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/power/test_crossover.py +0 -0
  179. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/power/test_means.py +0 -0
  180. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/power/test_noninferiority.py +0 -0
  181. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/power/test_proportions.py +0 -0
  182. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/tests/power/test_survival.py +0 -0
  183. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/validation/README.md +0 -0
  184. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/validation/pyproject.toml +0 -0
  185. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/validation/pystatsbioval/__init__.py +0 -0
  186. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/validation/pystatsbioval/device.py +0 -0
  187. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/validation/pystatsbioval/estimates.py +0 -0
  188. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/validation/pystatsbioval/measure.py +0 -0
  189. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/validation/pystatsbioval/record.py +0 -0
  190. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/validation/pystatsbioval/rrunner.py +0 -0
  191. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/validation/pystatsbioval/serialize.py +0 -0
  192. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/validation/pystatsbioval/timing.py +0 -0
  193. {pystatsbio-4.0.2 → pystatsbio-4.0.3}/validation/tests/test_harness.py +0 -0
@@ -1,5 +1,25 @@
1
1
  # Changelog
2
2
 
3
+ ## 4.0.3
4
+
5
+ - `pk.nca` now delegates terminal-slope (lambda_z) estimation to
6
+ `pystatistics.regression.simple_ols` instead of `scipy.stats.linregress`
7
+ (`pystatsbio/pk/_nca.py::_estimate_lambda_z`). Estimated lambda_z, adjusted
8
+ R-squared, and the selected terminal window are unchanged: the adjusted
9
+ R-squared best-fit (ARS) window-selection rule and its 1e-4 near-tie
10
+ tolerance are preserved exactly. Requires `pystatistics>=5.1` (raised from
11
+ `>=5.0`).
12
+ - Degenerate terminal windows in `pk.nca` are now handled through the library's
13
+ own error type instead of depending on scipy's edge-case behaviour: a
14
+ zero-variance window raises `LambdaZEstimationError` (fixed
15
+ `lambda_z_n_points=`) or is skipped as a candidate (auto-select), which
16
+ `nca()` reports as `lambda_z=None` plus an explanatory warning. This is
17
+ defensive hardening, not a user-visible fix — duplicate time points are
18
+ already rejected at input validation, and a flat terminal window already
19
+ failed the existing non-negative-slope check. Previously a zero-variance
20
+ window would have surfaced as a raw `scipy` `ValueError` escaping `nca()`.
21
+
22
+
3
23
  ## 4.0.2
4
24
 
5
25
  ### Summary
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pystatsbio
3
- Version: 4.0.2
3
+ Version: 4.0.3
4
4
  Summary: Biotech and pharmaceutical statistical computing for Python
5
5
  Project-URL: Homepage, https://sgcx.org/technology/pystatsbio/
6
6
  Project-URL: Documentation, https://sgcx.org/docs/pystatsbio/
@@ -23,7 +23,7 @@ Classifier: Topic :: Scientific/Engineering :: Medical Science Apps.
23
23
  Classifier: Typing :: Typed
24
24
  Requires-Python: >=3.11
25
25
  Requires-Dist: numpy>=1.24
26
- Requires-Dist: pystatistics>=5.0
26
+ Requires-Dist: pystatistics>=5.1
27
27
  Requires-Dist: scipy>=1.10
28
28
  Provides-Extra: all
29
29
  Requires-Dist: furo; extra == 'all'
@@ -415,7 +415,7 @@ pip install pystatsbio[gpu]
415
415
  pip install pystatsbio[dev]
416
416
  ```
417
417
 
418
- Requires Python 3.11+. Core dependencies: `pystatistics`, `numpy`, `scipy`.
418
+ Requires Python 3.11+. Core dependencies: `pystatistics>=5.1`, `numpy`, `scipy`.
419
419
 
420
420
  ---
421
421
 
@@ -368,7 +368,7 @@ pip install pystatsbio[gpu]
368
368
  pip install pystatsbio[dev]
369
369
  ```
370
370
 
371
- Requires Python 3.11+. Core dependencies: `pystatistics`, `numpy`, `scipy`.
371
+ Requires Python 3.11+. Core dependencies: `pystatistics>=5.1`, `numpy`, `scipy`.
372
372
 
373
373
  ---
374
374
 
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "pystatsbio"
7
- version = "4.0.2"
7
+ version = "4.0.3"
8
8
  description = "Biotech and pharmaceutical statistical computing for Python"
9
9
  readme = "README.md"
10
10
  license = "MIT"
@@ -36,12 +36,13 @@ classifiers = [
36
36
  "Typing :: Typed",
37
37
  ]
38
38
  dependencies = [
39
- # Requires pystatistics 5.0: pystatsbio 3.0 tracks the settled post-5.0
40
- # surface (5.0's exception taxonomy, de-dotted values, and the
39
+ # Requires pystatistics 5.1: pk.nca delegates terminal-slope (lambda_z)
40
+ # estimation to regression.simple_ols, added in 5.1. The 5.0 surface is
41
+ # still tracked (5.0's exception taxonomy, de-dotted values, and the
41
42
  # Result[*Params] / *Solution result objects). The GPU-precision-in-the-
42
43
  # backend-string convention (gpu_fp64) and core.compute.backend messages
43
44
  # that gee() uses were carried forward from 4.0.
44
- "pystatistics>=5.0",
45
+ "pystatistics>=5.1",
45
46
  "numpy>=1.24",
46
47
  "scipy>=1.10",
47
48
  ]
@@ -9,7 +9,7 @@ Usage:
9
9
  from pystatsbio import power, doseresponse, diagnostic, pk
10
10
  """
11
11
 
12
- __version__ = "4.0.2"
12
+ __version__ = "4.0.3"
13
13
  __author__ = "Hai-Shuo"
14
14
  __email__ = "contact@sgcx.org"
15
15
 
@@ -29,7 +29,7 @@ import numpy as np
29
29
  from numpy.typing import NDArray
30
30
  from pystatistics.core.exceptions import ConvergenceError, ValidationError
31
31
  from pystatistics.core.result import Result
32
- from scipy import stats
32
+ from pystatistics.regression import simple_ols
33
33
 
34
34
  from pystatsbio.pk._common import NCAParams, NCASolution
35
35
 
@@ -102,7 +102,7 @@ def _auc_loglinear_segment(t1: float, t2: float, c1: float, c2: float) -> float:
102
102
  """
103
103
  if c1 <= 0 or c2 <= 0 or c1 == c2:
104
104
  return _auc_linear_segment(t1, t2, c1, c2)
105
- return (c1 - c2) * (t2 - t1) / np.log(c1 / c2)
105
+ return float((c1 - c2) * (t2 - t1) / np.log(c1 / c2))
106
106
 
107
107
 
108
108
  def _compute_auc_segments(
@@ -168,7 +168,7 @@ def _aumc_loglinear_segment(
168
168
  if c1 <= 0 or c2 <= 0 or c1 == c2:
169
169
  return _aumc_linear_segment(t1, t2, c1, c2)
170
170
  k = np.log(c1 / c2) / (t2 - t1)
171
- return (t1 * c1 - t2 * c2) / k + (c1 - c2) / (k * k)
171
+ return float((t1 * c1 - t2 * c2) / k + (c1 - c2) / (k * k))
172
172
 
173
173
 
174
174
  def _compute_aumc_segments(
@@ -257,8 +257,9 @@ def _estimate_lambda_z(
257
257
  Raises
258
258
  ------
259
259
  LambdaZEstimationError
260
- If there are insufficient terminal phase points or the fitted slope
261
- is non-negative (not a true elimination phase).
260
+ If there are insufficient terminal phase points, the fixed terminal
261
+ window is degenerate (zero-variance time or log-concentration), or the
262
+ fitted slope is non-negative (not a true elimination phase).
262
263
  """
263
264
  # Terminal phase candidates: after Cmax, positive concentration
264
265
  idx_last = _find_last_measurable(concentration)
@@ -268,7 +269,7 @@ def _estimate_lambda_z(
268
269
  )
269
270
 
270
271
  # Candidates: indices from Cmax+1 to last measurable (inclusive)
271
- candidates = []
272
+ candidates: list[int] = []
272
273
  for i in range(idx_cmax + 1, idx_last + 1):
273
274
  if concentration[i] > 0:
274
275
  candidates.append(i)
@@ -288,25 +289,30 @@ def _estimate_lambda_z(
288
289
  f"(need at least 3)."
289
290
  )
290
291
 
291
- candidates = np.array(candidates)
292
+ candidate_idx: NDArray[np.intp] = np.asarray(candidates, dtype=np.intp)
292
293
 
293
294
  if n_points is not None:
294
295
  # Fixed number of terminal points (from the end)
295
296
  if n_points < 3:
296
297
  raise ValidationError("lambda_z_n_points must be >= 3")
297
- if n_points > len(candidates):
298
+ if n_points > len(candidate_idx):
298
299
  raise ValidationError(
299
300
  f"lambda_z_n_points={n_points} exceeds available "
300
- f"terminal points ({len(candidates)})"
301
+ f"terminal points ({len(candidate_idx)})"
301
302
  )
302
- idx_use = candidates[-n_points:]
303
+ idx_use = candidate_idx[-n_points:]
303
304
  t_fit = time[idx_use]
304
305
  log_c_fit = np.log(concentration[idx_use])
305
- slope, _, r_value, _, _ = stats.linregress(t_fit, log_c_fit)
306
+ try:
307
+ fit = simple_ols(t_fit, log_c_fit)
308
+ except ValidationError as exc:
309
+ raise LambdaZEstimationError(
310
+ f"Cannot estimate lambda_z: the fixed terminal window of "
311
+ f"{n_points} point(s) is degenerate ({exc})."
312
+ ) from exc
313
+ slope = fit.slope
306
314
  n_fit = n_points
307
- # Adjusted R-squared
308
- r_sq = r_value ** 2
309
- r_sq_adj = 1.0 - (1.0 - r_sq) * (n_fit - 1) / (n_fit - 2) if n_fit > 2 else r_sq
315
+ r_sq_adj = fit.adjusted_r_squared
310
316
  else:
311
317
  # Auto-select the terminal window by the "Adjusted R-squared Best Fit"
312
318
  # (ARS) rule used by Phoenix WinNonlin / R NonCompart::sNCA: fit the last
@@ -316,17 +322,17 @@ def _estimate_lambda_z(
316
322
  # strict argmax) is the pharmacometrics standard and matches the reference
317
323
  # NCA tools.
318
324
  fits = [] # (n_try, slope, r_sq_adj)
319
- for n_try in range(3, len(candidates) + 1):
320
- idx_use = candidates[-n_try:]
321
- s, _, r_value, _, _ = stats.linregress(
322
- time[idx_use], np.log(concentration[idx_use])
323
- )
324
- r_sq = r_value ** 2
325
- r_sq_adj_try = 1.0 - (1.0 - r_sq) * (n_try - 1) / (n_try - 2)
326
- fits.append((n_try, s, r_sq_adj_try))
325
+ for n_try in range(3, len(candidate_idx) + 1):
326
+ idx_use = candidate_idx[-n_try:]
327
+ try:
328
+ fit = simple_ols(time[idx_use], np.log(concentration[idx_use]))
329
+ except ValidationError:
330
+ # A flat/degenerate window (zero-variance time or
331
+ # log-concentration) is not a usable candidate. Skip it, so the
332
+ # elimination-phase check below fails loud when no window is.
333
+ continue
334
+ fits.append((n_try, fit.slope, fit.adjusted_r_squared))
327
335
 
328
- # A flat/degenerate profile gives a non-finite adjusted R-squared; drop
329
- # those so the elimination-phase check below fails loud (lambda_z=None).
330
336
  finite_fits = [f for f in fits if np.isfinite(f[2])]
331
337
  if not finite_fits:
332
338
  slope, r_sq_adj, n_fit = None, float("nan"), 0
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes