π¬ Fifth and final lab#
π Task 5.1: Coding up the stochastic consumption-savings model#
β± Expected work time 60 minutes
Letβs implement EGM and a simulator for the consumption-savings model.
βοΈ Use the Jupyter notebook
egm.ipynbβοΈ Fill out the gaps in the code to eliminate all run-time errors
βοΈ Perform all the tests following the tasks in the notebook
π Task 5.2: Estimating consumption savings model by MSM#
β± Expected work time 60 minutes
In this task you run an MSM estimation exercise for the consumption-savings model.
βοΈ Use the Jupyter notebook
msm_estim.ipynbβοΈ Make sure you understand the code in the notebook β correspond different parts of the code to the theory covered in the lecture notes
βοΈ Fill in the gaps in the code to eliminate all run-time errors
βοΈ Run the MSM estimation procedure
βοΈ Experiment with how the estimate changes when you modify:
(a) the number of simulated households
(b) the number of time periods
(c) the weighting matrix
βοΈ [Optional] Write a Monte Carlo loop to assess the estimatorβs performance. On each iteration it should:
(a) Simulate a new dataset for the known values of the parameters
(b) Estimate the model using MSM
(c) Store the estimates for later analysis
(d) After completing all iterations, analyze the distribution of the estimates (mean, variance, bias, etc.) to evaluate the estimatorβs performance.