Skip to content

Commit

Permalink
Only Plot Nominal Variable separately in Sensitivity Analysis plot (#…
Browse files Browse the repository at this point in the history
…2381)

Summary:

In Sensitivity Analysis plot, we want to plot (unordered) categorical separately and shows that it "affects" metrics while still showing "increases"/"decreases" metrics for ordinal variables.

Differential Revision: D56325368
  • Loading branch information
Sunny Shen authored and facebook-github-bot committed Apr 18, 2024
1 parent eef87a0 commit 6440613
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ax/plot/feature_importances.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ def plot_feature_importance_by_feature_plotly(
categorical_features = [
name
for name, par in model.model_space.parameters.items()
if isinstance(par, ChoiceParameter)
if isinstance(par, ChoiceParameter) and not par.is_ordered
]

for i, metric_name in enumerate(sorted(sensitivity_values.keys())):
Expand Down

0 comments on commit 6440613

Please sign in to comment.