Global Post-Hoc Methods

Global post-hoc methods try to answer questions such as:

  • Which features matter most overall?
  • How does the prediction change as one feature moves?
  • Where do strong interactions appear?
  • Can a simpler model approximate the black box reasonably well?

They do not explain every individual decision, but they give us a high-level map of model behavior.

Permutation Feature Importance (PFI) measures how much performance drops when we randomly shuffle one feature while keeping the trained model fixed.

\[ I_j = \text{score}(f, X, y) - \text{score}(f, \widetilde{X}^{(j)}, y) \]

If performance falls sharply, that feature was important to the model. If almost nothing changes, the feature was not contributing much.

The main caveat from the lecture is correlation: if two features carry similar information, permuting one may understate its true importance because the other can partially replace it.

Partial Dependence Plots (PDP) average the model response over the dataset while varying one feature:

\[ \hat f_S(x_S) = \frac{1}{n}\sum_{i=1}^n \hat f(x_S, x_C^{(i)}). \]

This gives a global view of how the prediction changes with that feature.

ICE plots keep the same idea but draw one curve per observation instead of averaging immediately. That makes heterogeneity visible: two individuals can react very differently to the same feature change even if the PDP looks smooth.

Both methods rely on an independence-style assumption when we vary one feature and hold the others fixed, so correlated features can again make the picture less realistic.

The lecture also covers three complementary global tools.

  • LOFO importance: retrain the model without one feature and measure the performance loss. It is often more realistic than pure permutation, but much more expensive.
  • H-statistic for interaction strength: quantify how much of the prediction variance comes from interactions rather than additive main effects.
  • Global surrogate models: train a simple interpretable model to mimic the black box. If the surrogate fits well, it can provide a readable approximation of the original system.

For LOFO, the idea is close to:

\[ \mathrm{LOFO}_j = \mathrm{score}(f, X, y) - \mathrm{score}(f_{-j}, X_{-j}, y), \]

where \(f_{-j}\) is a model retrained without feature \(j\).

For a surrogate model \(g\), we often optimize a fidelity objective of the form

\[ g^* = \arg\min_{g \in G} \sum_{i=1}^n \bigl(f(x_i) - g(x_i)\bigr)^2. \]

Surrogates are useful, but only when we also check their fidelity. A simple explanation that poorly matches the original model can be dangerously comforting.

In this lesson we covered:

  1. Global feature importance with permutation and LOFO
  2. Response-shape tools with PDP and ICE
  3. Interaction analysis with the H-statistic
  4. Surrogate models as approximations of a black box

Next: We move from whole-model summaries to local explanations for individual predictions.