Skip to content

Interactions plot parity with contribution plot (multiclass label, crossed sampling, jittering) #757

Description

@guillaume-vignal

Summary

interactions_plot and top_interactions_plot are not fully aligned with contribution_plot for multiclass behavior and interaction readability.

Problem

  • Multiclass interaction values may come from SHAP in output-specific formats (list/4D), which can break plotting if not normalized.
  • Interaction analysis should support class selection (label) like contribution_plot.
  • Smart sampling for interactions should preserve the joint distribution of the 2 selected variables.
  • Violin interaction rendering should include jittered point dispersion for readability while preserving true hover values.
  • Postprocessed/display values should be consistently used in interaction axes and hover.

Expected Behavior

  • interactions_plot and top_interactions_plot accept label and display class-specific interactions in classification.
  • SHAP interaction outputs are robustly handled for multiclass/multi-output formats.
  • Smart sampling for interactions is based on crossed variables.
  • Violin mode shows jittered points with non-jittered values in hover.
  • Postprocessed values are consistently reflected in interaction visual outputs.

Impact

This improves parity with contribution_plot, prevents multiclass edge-case failures, and makes interaction plots more interpretable and stable.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions