🔬 Second lab#
🛠 Task 2.1: Finish the implementation of the static logit model#
⏱ Expected work time 60 minutes
Continue with the rest of the Task 1.5 from the First Lab
☑️ Follow instructions in the notebook
lab1/logit_pre.ipynb☑️ Spend considerable time to play with the model using graphical tools
What effect does a change in each parameter have? Can we use the previous question to build intuition of identification?
🛠 Task 2.2: Rationalizing the existing code of MLE estimation#
⏱ Expected work time 30 minutes
☑️ Find a complete code of an MLE estimation of a particular location choice model in
lab2/location_choice/directory☑️ Install the required packages, and run the estimation code
☑️ Study all parts of the code, making sure you understand how everything works together
☑️ Write down specification of the model being estimated, including the utility and likelihood function
☑️ Reestimate the model by including all the variables available in the provided dataset
☑️ Look for an optimal selection of explanatory variables, and report the final estimation results
🛠 Task 2.3 [optional]: Implementing MLE estimator for the static logit model#
⏱ Expected work time 120 minutes
☑️ Return to the implementation of the static discrete choice model, a copy of the solution is in
lab2/logit.ipynb☑️ Code up a likelihood function that can be called to compute the log-likelihood of the simulated dataset
☑️ Use
scipy.optimize.minimizeto find the MLE estimates☑️ Write code for a Monte Carlo study by simulating new samples from the model for known true parameter values, estimate the model on each sample, and report the bias and RMSE of the estimates. Optionally make histograms of the estimates over the Monte Carlo replications.