Gale–Shapley Deferred Acceptance Algorithm Playground
Try the live demo → · View the code on GitHub →
The Gale–Shapley Deferred Acceptance Algorithm solves two-sided matching problems such as assigning medical residents to hospitals. I built an interactive Shiny for Python visualizer to explore how the algorithm works and how outcomes change depending on which side proposes.
You can create your own matching market with custom preference rankings, hospital capacities, and unacceptable matches, then run either the doctor-proposing or hospital-proposing algorithm step-by-step to follow each proposal, rejection, and tentative match.
Tools: Python · Shiny for Python · Shinylive