cranalytics
cranalytics is a DataFrame-first toolkit for practical credit risk work: vintage curves, lifetime loss forecasting, portfolio segmentation, feature analytics, ML modeling, and rollforward operating diagnostics.
Run cranalytics quickstart
Open the Gallery
- Start Here
Best first step if you are new to the package.
cranalytics quickstart
Expect: one guided workflow, one first win, one obvious next step.
- Visual Tour
Best if you want to scan examples before reading tutorials.
python -m cranalytics.examples.core_vintage
Expect: concrete example commands and outcomes by workflow.
- Pick By Problem
Best if you already know the risk question or data shape.
cranalytics rollforward-readiness your_rollforward_data.csv --output-dir rollforward_readiness_out
Expect: fast routing to the right workflow and next doc.
Core Workflows
- Vintage Curve Fitting
Fit cumulative loss by cohort.
First run:
python -m cranalytics.examples.core_vintage
First win: Fitted curve and ultimate loss estimate.
- Lifetime Loss Forecasting
Estimate reserve from a transition matrix or loan history.
First run:
python -m cranalytics.examples.core_lifetime_loss
First win: Reserve estimate on a mock portfolio.
- FICO Segmentation
Bucket the portfolio by score band and simple risk grade.
First run:
python -m cranalytics.examples.core_segmentation
First win: FICO-band table and mix diagnostics.
- Feature Analytics
Rank signal before committing to model training.
First run:
python -m cranalytics.examples.core_feature_analytics
First win: Ranked feature table.
- ML Modeling
Backtest, train, and score baseline models.
First run:
python -m cranalytics.examples.core_ml_modeling
First win: Fold-level backtest summary table.
- Rollforward Workflow
Validate monthly aggregated rollforward data before operational use.
First run:
cranalytics rollforward-readiness your_rollforward_data.csv --output-dir rollforward_readiness_out
First win: Readiness report directory and diagnostics.
Read In This Order
API Entry Points
- Vintage & Smoothing API
- Core API Reference
- Loss Forecasting API
- Predictive Modeling API
- Rollforward Workflow API
Optional Extras
pip install "cranalytics[ml]"
pip install "cranalytics[xgboost]"
pip install "cranalytics[lightgbm]"