Skip to content

Commit 5871f0b

Browse files
committed
Fix issue where target_index was not being properly set
1 parent 1c032e2 commit 5871f0b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/sasctl/pzmm/write_score_code.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1121,6 +1121,8 @@ def _predictions_to_metrics(
11211121
are not given, this index should indicate whether the the target probability variable
11221122
is the first or second variable returned by the model. The default value is 1.
11231123
"""
1124+
if not target_index:
1125+
target_index = 1
11241126
if len(metrics) == 1 and isinstance(metrics, list):
11251127
# Flatten single valued list
11261128
metrics = metrics[0]

0 commit comments

Comments
 (0)