rebasing#791
Merged
Merged
Conversation
…nctions to sparse.COO, and keep module-level functions to sp. Replaces xp() with xp.COO() to create sparse arrays when xp used to be callable and was used as a constructor.
Bumps [mistune](https://github.com/lepture/mistune) from 3.1.4 to 3.2.1. - [Release notes](https://github.com/lepture/mistune/releases) - [Changelog](https://github.com/lepture/mistune/blob/main/docs/changes.rst) - [Commits](lepture/mistune@v3.1.4...v3.2.1) --- updated-dependencies: - dependency-name: mistune dependency-version: 3.2.1 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com>
Build(deps): Bump mistune from 3.1.4 to 3.2.1
Update pyproject.toml - Add numpy #738
Enhance docstrings and examples for improved clarity for many estimators
…nto 0.9.2-release-prep
Closes #757 The Adjustments section header in docs/library/api.md was a copy-paste of the Workflow section. The :mod: link and .. automodule:: directive both pointed at chainladder.workflow, so the rendered RTD page for Adjustments hyperlinked to the Workflow module page. The four classes listed under Adjustments (BootstrapODPSample, BerquistSherman, Trend, ParallelogramOLF) all live in chainladder.adjustments, which is the correct target. Co-authored-by: Nick Kinney <nkinney06@gmail.com>
…p() (#761) Per maintainer feedback on #758/#761: matplotlib is needed at runtime for TriangleDisplay.heatmap() even though it isn't imported directly, so it must remain a core dependency. Add an inline comment so future contributors don't try to move it again. Co-authored-by: Nick Kinney <nkinney06@gmail.com>
…nto 0.9.2-release-prep
REFACTOR: Reorganize type hierarchy of sparse.py. Move array-level fu…
Bumps [urllib3](https://github.com/urllib3/urllib3) from 2.6.3 to 2.7.0. - [Release notes](https://github.com/urllib3/urllib3/releases) - [Changelog](https://github.com/urllib3/urllib3/blob/main/CHANGES.rst) - [Commits](urllib3/urllib3@2.6.3...2.7.0) --- updated-dependencies: - dependency-name: urllib3 dependency-version: 2.7.0 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com>
Build(deps): Bump urllib3 from 2.6.3 to 2.7.0
…nto 0.9.2-release-prep
v.0.9.2 release notes
Adds the clrd2025 branch in load_sample mirroring the existing clrd config, but using the modernized CAS Schedule P column names (IncurredLosses rather than IncurLoss). Updates the docstring's complete dataset list and the sample-data documentation page. Adds a targeted test asserting the six LOBs, modern column names, and origin starting at 1998. The underlying clrd2025.csv was added by @kennethshsu on branch #745. Closes part of #745.
feat(data): wire clrd2025 into load_sample, docs, and tests (#745)
#765) (#777) * test(development): assert exclusions-ignored UserWarning in drop tests (#765) Per #765, ~75 UserWarnings firing from chainladder/development/base.py during tests that deliberately exercise the drop/exclusion path were not being asserted. Wrapping each warning-producing call in `pytest.warns(UserWarning, match=...)` makes the contract explicit: the test fails if the warning stops firing OR if its message changes. Per @kennethshsu's preference on the issue thread, used the `pytest.warns` idiom uniformly (no blanket `@pytest.mark.filterwarnings`), so each individual call site that should warn does so observably. Affected tests (chainladder/development/tests/): - test_development.py: test_drophighlow (5 of 7 calls), test_new_drop_5, test_new_drop_5a (both _set_weight_func calls), test_new_drop_7, test_pipeline (both fits) - test_incremental.py: test_pipeline (both fits); added `import pytest` The two `test_drophighlow` calls that don't warn (`drop_high=0` and `drop_high=[T,F,T,F]`) were left untouched — wrapping them would incorrectly require a warning that doesn't fire. Verified locally: 671 passed, 12 xfailed (pre-existing). Targeted 6-test 'exclusions ignored' warning count drops from 10 to 4 in the pytest summary (the remaining 4 are pytest's source-line accounting from inside the `pytest.warns` blocks, not leaked warnings). Refs #765. * Annotate exclusions-ignored warning as test-asserted Add an in-source comment above each warnings.warn(...) call for the 'Some exclusions have been ignored...' UserWarning, noting that the message is matched by pytest.warns(..., match=...) in the development test suite. Future edits to the warning text must update the corresponding test matchers. Addresses review feedback on #777.
* Implemented policy_length * undo the refactor * added tests for policy_length * Fixed bug to round D to int * Fixed an issue on the tests * Removed blank line * Formatted with black * Added more tests * clarification * Moved the parallelogram tests from utilities to parallelogram file * Refactored leap and nonleap * Improved docstring with assumption * Refactored, all bugs resolved * Cleaned up debugger * Clean up, removed debugger * Added a guard to prevent averaging nothing * Added another simple example * Added Henry's tests * Fixed bugbot errors * Added 2 new tests * Removed the fstring
* Improved docstring and added two examples * Added a new test iat exceptions - thanks HL * Allowing project to drop a threshold of 0.1%
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## experimental #791 +/- ##
================================================
+ Coverage 85.94% 86.17% +0.22%
================================================
Files 85 86 +1
Lines 4924 4925 +1
Branches 637 639 +2
================================================
+ Hits 4232 4244 +12
+ Misses 491 484 -7
+ Partials 201 197 -4
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary of Changes
Related GitHub Issue(s)
Additional Context for Reviewers
uv run pytest) and documentation changes (uv run jb build docs --builder=custom --custom-builder=doctest)Note
Medium Risk
Changes the
ParallelogramOLFon-level factor calculation API/behavior via a newpolicy_lengthparameter and updates CI to run on all pushes, which could affect downstream results and build frequency but is well-covered by new tests.Overview
Enhances
ParallelogramOLF/parallelogram_olfto support a configurablepolicy_length(in months) and clarifies the API by switching the helper parameter name todates, with updated docs/examples for daily vs monthly approximations.Greatly expands
test_parallelogram.pyto validate vertical vs non-vertical methods,policy_lengtheffects, and daily/monthly behavior; updates development pipeline tests to explicitly assert the existing “Some exclusions have been ignored…” warning, and adds slicing accessor exception tests.Packaging/ops tweaks: includes the
clrd2025.csvsample inMANIFEST.in, refreshes README badges (adds conda-forge), and enables the unit test workflow to run onpushto all branches.Reviewed by Cursor Bugbot for commit f28473d. Bugbot is set up for automated code reviews on this repo. Configure here.