Repository navigation
chang_credible: pass scatter's size, colour and marker by keyword - #419
Conversation
plot_equilibria passed `s`, `c` and `marker` to Axes.scatter positionally. Passing `marker` positionally is deprecated since Matplotlib 3.10 and becomes keyword-only in 3.12, so each of the page's two calls of plot_equilibria printed a MatplotlibDeprecationWarning into its output. The values are unchanged, so the figure is the same. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WT8bMacV9Lmy1VLUc6XJoL
✅ Deploy Preview for lustrous-melomakarona-3ee73e ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
ValidationThis pull request's build, 45009483978 at
Against 45001954151, two pages differ, out of 85:
The build log has no Sphinx warning. (Corrected 2026-11-22: the page has two figures, one per plot_equilibria call; the conclusion is unchanged.) |
There was a problem hiding this comment.
🔵 Needs a closer look
Human review is warranted because the change affects executable lecture content and rendered educational figures, requiring confirmation that the documented output and Matplotlib visuals remain equivalent across supported build environments.
No open issues 🎉
What changed in this PR
Updates the chang_credible lecture to use keyword arguments for Matplotlib's Axes.scatter, eliminating the positional marker deprecation while preserving the existing plot output.
Changes:
- Passes scatter size, colour, and marker via
s,c, andmarkerkeywords. - Keeps the existing plotting values and behavior unchanged.
| File | Description |
|---|---|
| lectures/chang_credible.md | Updates the plot_equilibria scatter call to use keyword arguments for marker size, colour, and style. |
Review effort: Lite (adaptive)
What
plot_equilibriain chang_credible passed the size, colour and marker toAxes.scatterpositionally:ax.scatter(R[0], R[1], 150, 'black', 'o', zorder=1)ax.scatter(R[0], R[1], s=150, c='black', marker='o', zorder=1)Passing
markerpositionally has been deprecated since Matplotlib 3.10, and it becomes keyword-only in 3.12. So each of the page's two calls ofplot_equilibriaprints this into its output:The values are unchanged, so the figure should be the same. The two warnings were found by the environment scan of 2026-11-19, for QuantEcon/project-monorepo#77, and they are also in the build of this site from the lecture monorepo, QuantEcon/lectures#86.
lecture-dppublishes a copy of this lecture with the same line; it follows once this is merged.Validation
Done on 2026-11-22; the evidence is in the comment below. The build re-executed chang_credible: the two warnings are gone, the three figures are byte-identical to main's, and nothing else on the page changed.
This changes lecture content, so it needs a person's review.
🤖 Generated with Claude Code
https://claude.ai/code/session_01WT8bMacV9Lmy1VLUc6XJoL