Question Description

I’m working on a Economics question and need guidance to help me study.

Lab Assignment 1

1. Generate a covariate matrix X of dimension n × k, where n = 500 and k = 4. The first column in X should be a column of ones and the other three columns can be generated from a relatively diffuse normal or uniform distribution. Let β = (1, 1.25, 1.5, 1.75)0 and let σ 2 = 1. Simulate y from the model y = Xβ +ε, where ε ∼ N(0, σ2 In). Estimate β by ordinary least squares and report βˆOLS and the standard errors in a table. [Hint: the standard errors are computed by taking the square root of the main diagonal of s 2 (X0X) −1 , where s 2 is computed as discussed in class.] Also submit your computer code (this should not take more than 20 lines). For this exercise, the TAs will provide support on coding in Matlab (free on Apporto - see the link to VCL on Canvas), but you can use any software you are comfortable with. The idea behind this exercise is not to use packages or click on buttons, but to do the coding from scratch, following the theoretical derivations presented in class.

EssayLoop’s team of experts are available 24/7 to assist you in completing such tasks. Place your order at EssayLoop.com by clicking on the ORDER NOW option and get a 20% discount on your first assignment.