Skip to content

Newt

A lightweight Python toolkit for efficient feature analysis and statistical diagnostics in credit risk modeling.

Key Features

  • 6 Binning Algorithms: ChiMerge, Decision Tree, K-Means, Equal Frequency, Equal Width, Optimal.
  • Monotonic Support: Comprehensive monotonic binning support (ascending, descending, auto-detect).
  • Feature Analysis: Robust binning statistics and transformation workflows.
  • Feature Selection: Pipeline-style feature selection (IV, PSI, VIF, Stepwise).
  • Scorecard Generation: End-to-end scorecard generation and scoring.
  • High Performance: Rust-accelerated core paths with component-specific engine defaults (for example, IV/FeatureSelector/Report use auto).

Installation

pip install newt

Quick Start

Recommended workflow: fit Binner, call binner.woe_transform(X), then build the scorecard with Scorecard.from_model(model, binner). For persistence, use LogisticModel.dump/load and Scorecard.dump/load.

Benchmarks