QuantEcon / QuantEcon/lecture-python.myst
[organization_capital] posterior-mean figure does not show the convergence the text describes
Nobody has claimed this yet.
- Dominant language
- TeX
- Stars
- 123
- Forks
- 57
- Avg merge
- 3d 10h
- Merged PRs (30d)
- 11
Description
In lectures/organization_capital.md, the cell producing the "Posterior mean convergence and uncertainty" figure simulates a single worker with T = 20. The text just below it says:
As the number of screening observations $n$ increases, the posterior mean converges to the true $\theta$, and the posterior uncertainty shrinks at rate $1/\sqrt{n}$.
The posterior mean in the left panel does not converge to θ_true = 0.8. It wanders and ends well away from it.
This is about the sample size rather than the seed: PR #1014 migrates the cell to np.random.default_rng(0), which changes the draws but not this behaviour. Screenshots of the figure before and after that migration are attached below.
Before the migration:
After the migration:
Two ways to make the figure match the text:
- Increase
T. - Or soften the prose so that it describes what the figure shows at
T = 20.
CC @mmcky and @HumphreyYang.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Open lectures/organization_capital.md and inspect the cell producing the "Posterior mean convergence and uncertainty" figure, including its T = 20 setting and the prose below it. Rerun the cell to compare the posterior mean with θ_true = 0.8, then either adjust the sample size or revise the explanation so the figure and text agree.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data-visualization, documentation
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 74/100