optbinning/invalid-monotonic-trend
| Pack | Severity | Fix | Versions |
|---|---|---|---|
| optbinning | error | none, edit by hand | All versions |
optbinning uses "ascending" and "descending" (plus "auto", "auto_heuristic", "auto_asc_desc", "concave", "convex", "peak", "valley", "peak_heuristic", "valley_heuristic", or None) for monotonic_trend. Passing "increasing", "decreasing", 1, -1, or True raises ValueError during fit().
optb = OptimalBinning(monotonic_trend="increasing")optb = OptimalBinning(monotonic_trend="ascending")What the rule reports
Section titled “What the rule reports”Calls to OptimalBinning, ContinuousOptimalBinning, MulticlassOptimalBinning, OptimalPWBinning, ContinuousOptimalPWBinning, OptimalBinningSketch, or SBOptimalBinning passing a string, integer, or boolean literal outside the allowed monotonic_trend values.
How to fix it
Section titled “How to fix it”Replace "increasing" with "ascending", "decreasing" with "descending", or select another documented optbinning trend option.
Diagnostic message
Section titled “Diagnostic message”Invalid optbinning monotonic_trend=$TREND raises ValueError at fit time. Use one of "auto", "auto_heuristic", "auto_asc_desc", "ascending", "descending", "concave", "convex", "peak", "valley", "peak_heuristic", "valley_heuristic", or None.See all rules in the optbinning pack.