← Latest papers
📊 statistics

Fast approximate estimation of conditional Shapley values when using a linear explainer

This paper introduces three new methods, including an exact approach and two approximate ones, that leverage constrained Gaussian Markov Random Field theory and sparse matrix algebra to rapidly and accurately estimate conditional Shapley values for linear models by jointly computing all submodels, thereby significantly reducing computation time compared to existing sequential or iterative techniques while maintaining or improving accuracy.

Original authors: Fredrik Lohne Aanes

Published 2026-07-28
📖 3 min read☕ Coffee break read

Original authors: Fredrik Lohne Aanes

Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

Imagine you are trying to figure out why a specific prediction was made by a complex computer program, like a loan approval system or a medical diagnosis tool. You want to know: "How much did your age contribute? How much did your income contribute?" In the world of data science, this is called finding "Shapley values." Think of it like a team project where everyone gets a grade, but you need to calculate exactly how much credit each team member deserves for the final score. The tricky part is that these team members (the data features) often rely on each other. If you know someone is tall, you might guess they are older, so you can't just look at them in isolation; you have to see how they work together.

To do this mathematically, scientists use a "linear explainer," which is essentially a tool that builds many small, simple models to see how the prediction changes when you add or remove different pieces of information. However, there is a massive problem: if you have 20 different pieces of information, the number of possible combinations you need to check is over a million (2202^{20}). Trying to build a model for every single combination one by one is like trying to count every grain of sand on a beach by picking them up individually. It takes forever, and computers often get stuck or run out of memory. This is the bottleneck that makes explaining complex AI predictions so slow and difficult.

This paper, written by Fredrik Lohne Aanes, introduces a clever new way to solve this counting problem. Instead of building a million models one by one, the author suggests building a giant "super-model" that contains all the smaller models at once, using some fancy math tricks involving "sparse matrices" (which are just grids of numbers where most of the spots are empty zeros). The paper proposes three new methods to estimate these values quickly. Two of them are "approximate," meaning they use a mathematical shortcut that gets the answer almost perfectly, while the third is "exact," meaning it gets the answer perfectly without any shortcuts.

The author tested these new methods against the current standard software (called shapr) using real-world data about adult incomes, simulated data, and global life expectancy statistics. The results were striking. In cases where the old software took hours to calculate the values because it had to check almost every possible combination, the new methods finished the job in seconds or minutes. For example, on the adult income dataset, the old method took about 17 to 19 minutes, while the new methods took between 2.5 and 9 seconds. Even in a simulation where the old method was fast because it only checked a few combinations, the new methods still managed to check all 2 million possible combinations in under three minutes.

The paper suggests that while the approximate methods are incredibly fast, the "Exact transformation method" is the best choice because it requires no tuning knobs to adjust and gives results just as accurate as the others. The author concludes that by using these new techniques, we can finally explain complex models much faster, even when dealing with many different variables, without sacrificing accuracy. It's like swapping a slow, manual counting process for a high-speed scanner that sees the whole beach in a single glance.

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →