Skip to content

Create Scorecard API Reference

This page documents the API for the Create Scorecard function in Pypulate.

Scorecard creation for credit scoring.

create_scorecard(features, weights, offsets=None, scaling_factor=100.0, base_score=600)

Create a points-based scorecard for credit scoring.

Parameters:

Name Type Description Default
features dict

Dictionary of feature names and their values (e.g., {"income": 75000, "age": 35}).

required
weights dict

Dictionary of feature names and their weights (e.g., {"income": 0.3, "age": 0.5}).

required
offsets dict

Dictionary of feature names and offset values (default is 0 for each feature if None).

None
scaling_factor float

Scaling factor to divide the points, controlling the score range (default is 100.0).

100.0
base_score float

Base score to which feature points are added (default is 600).

600

Returns:

Type Description
dict

Dictionary containing the total score, points breakdown, and risk category.