Consolidation of Stats Warnings/Errors

Hi team, gh-14362 <https://github.com/scipy/scipy/issues/13462> reported that many hypothesis test-specific warnings had been added to the public API of `scipy.stats` without discussion on the mailing list. It recommended keeping things cleaner by creating a few superclass warnings to be used in the public API, and any existing test-specific warnings would inherit from these. gh-15923 <https://github.com/scipy/scipy/pull/15923> performs this consolidation, removing class-specific warnings like `F_onewayConstantInputWarning`, `PearsonRConstantInputWarning`, and `SpearmanRConstantInputWarning` from the documentation and adding a public `ConstantInputWarning` in their place. It also adds `NearConstantInputWarning` (in place of, e..g., `PearsonRNearConstantInputWarning`), `DegenerateDataWarning` (a superclass of the other new warnings), and `FitError` (to serve as a superclass for several errors raised when fitting distributions to data). If you're interested, please join the discussion in gh-15923. Thanks! Matt Haberland -- Matt Haberland Assistant Professor BioResource and Agricultural Engineering 08A-3K, Cal Poly

Hi team, gh-15923 <https://github.com/scipy/scipy/pull/15923> removed the function-specific stats warnings like `F_onewayConstantInputWarning`, `PearsonRConstantInputWarning`, and `SpearmanRConstantInputWarning` from the documentation and created appropriate superclasses. In addition, it was suggested that the function-specific warnings should be removed and entirely replaced by their superclasses. gh-16266 <https://github.com/scipy/scipy/pull/16266> attempted to do this with the usual deprecation cycle, but there doesn't seem to be a great way of doing it that warrants the effort, given the relatively low impact their removal is expected to have. Therefore, gh-16289 <https://github.com/scipy/scipy/pull/16289> proposes to remove the function-specific warnings immediately. If you're interested, please join the discussion in gh-16289. Thanks! Matt On Fri, Apr 8, 2022 at 11:28 AM Matt Haberland <mhaberla@calpoly.edu> wrote:
Hi team,
gh-14362 <https://github.com/scipy/scipy/issues/13462> reported that many hypothesis test-specific warnings had been added to the public API of `scipy.stats` without discussion on the mailing list. It recommended keeping things cleaner by creating a few superclass warnings to be used in the public API, and any existing test-specific warnings would inherit from these.
gh-15923 <https://github.com/scipy/scipy/pull/15923> performs this consolidation, removing class-specific warnings like `F_onewayConstantInputWarning`, `PearsonRConstantInputWarning`, and `SpearmanRConstantInputWarning` from the documentation and adding a public `ConstantInputWarning` in their place. It also adds `NearConstantInputWarning` (in place of, e..g., `PearsonRNearConstantInputWarning`), `DegenerateDataWarning` (a superclass of the other new warnings), and `FitError` (to serve as a superclass for several errors raised when fitting distributions to data).
If you're interested, please join the discussion in gh-15923. Thanks! Matt Haberland
-- Matt Haberland Assistant Professor BioResource and Agricultural Engineering 08A-3K, Cal Poly
-- Matt Haberland Assistant Professor BioResource and Agricultural Engineering 08A-3K, Cal Poly
participants (1)
-
Matt Haberland