Question

5) Simulate data according to the following. Please provide a log ile and any supporting exhibits x = 12 ,50 e N(0,1) a) Provide an estimate of the coefficients in y + + є b) Are Bi,B2 near the true values? c) Store the coefficients in a matrix B d) Repeat the simulation 100 times, estimating the equation and storing the coefficients each iirte e) What is the distribution of simulated coefficients A, B2? a. b. c. Mean Standard Deviation Relate these to the true values of the coefficients and the first two moments of the OLS estimator

Please complete the above question using STATA software.

I am not sure what you mean when you said you cannot complete it in the space provided- only a log file is needed.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

e rnorm (50,0,1) Beta2hat-(sum (X*Y)-50 mean (X) mean (Y)) /sum ( (X-mean (X))A2) Betalhat mean (Y)-Beta2hat mean (X) #The .Values of coefficients are Betalhat [11 1.260601 Beta2hat [11 1.99297 #0. b)-yes,,betalhat and beta2hat are near to their true values but slightly differ 2/11 992970 Frst and second row of BetaMatrix represent the. estimate of betal and beta2 respectively. meanbe 78654 mearbeta2 99916 0.

> e-rnorm(50, o, 1) Beta2hat (sum (X*Y)-50*mean (X) *mean (Y) )/sum ( (X-man (X) >Betalhat-mean (Y) -Beta2hat*mean (X) > The values of coefficients are Betalhat [11 1.260601 Beta2hat [11 1.99297 > #Q . b) yes ,betalhat and beta2hat are near to their true values butl slightly differ. > B#coeffient Matrix ,1.260601 2,1 1.992970 BetaMatrix=matrix (nrow=2, ncol=100) for 100 Be 2hat mean First and second row of BetaMatrix: ep esent the estimate of beta and ta2.espectively. meanbetai mean (BetaMatrix meanbeta2 1.99916 BetaMa SDbe Dbeta2 va

Add a comment
Know the answer?
Add Answer to:
Please complete the above question using STATA software. I am not sure what you mean when...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • 5) Simulate data according to the following. Please provide a log file and any supporting exhibits:...

    5) Simulate data according to the following. Please provide a log file and any supporting exhibits: x = 12 ,50 Y=1+2X + e e N(0,1) a) Provide an estimate of the coefficients in y BB2x +E b) Are B1 B2 "near" the true values? ) Store the coefficients in a matrix 8 d) Repeat the simulation 100 times, estimating the equation and storing the coefficients each time e) What is the distribution of simulated coefficients B.B2? a. b. c. Mean...

  • I only need Question 4 (Image above) answered. I am providing you with the rest of the questions and other information...

    I only need Question 4 (Image above) answered. I am providing you with the rest of the questions and other information for background information since it is necessary to answer Question 4. I do not need answers to Q1, 2 and 3 - only for Q4 Background information for the question: The dataset weightloss.dta contains information on 77 patients randomised to undertake one of three diets (referred to as diet A, B and C). Some background information is also available,...

  • Please tell me what I am missing to complete this question. Thank you. Exercise 14-3A Computing...

    Please tell me what I am missing to complete this question. Thank you. Exercise 14-3A Computing bond interest and price; recording bond issuance LO C2 Bringham Company issues bonds with a par value of $800,000 on their stated issue date. The bonds mature in 10 years and pay 6% annual interest in semiannual payments. On the issue date, the annual market rate for the bonds is 8%. (Table B.1, Table B.2, Table B.3, and Table B.4) (Use appropriate factor(s) from...

  • Can you please provide the formula for the worksheet also. CASE PROBLEMS Level 1- Analyzing Sales...

    Can you please provide the formula for the worksheet also. CASE PROBLEMS Level 1- Analyzing Sales for Crèmes Ice Cream Judd Hemming is the eastern regional marketing manager for Crèmes Ice Cream. Eac quarter, he completes two separate analyses: an analysis comparing ice cream flavor sale volumes from all regional locations with the same quarter sales volumes from the previou year and an analysis comparing total sales in dollars, including mean, median, mode, and standard deviation, of sales by store....

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT