hello,
As part of a Monte Carlo study
I have the following population regression model:
Y= 262 -0.006X2-2.4X3+u
I was told to assume that u is normally distributed with N(0,42)
I have to Generate 64 observations for u
I have to combine the observations with the 64 observations on X2 and X3 in a table that I already have to estimate the corresponding sample regression model Betahat1 Betahat 2 and Betahat3 using the OLS method. Save the estimated coefficients.
Then they want me to repeat that 20 times. Is there a shortcut to create u, u1,u2...u20 where each of them is N(0,42) and gets added to my editor then I want a command that regresses my X2 and X3 and each of the Us on my Y. So I have to have 20 regressions. I wanna do that in one command. Is there a way? Please help.
Related Posts with loops
Fixed effects models with instrumental variables and bootstrapped standard errors within clustersI'm trying to run some panel data, and the way the sampling occurred I should bootstrap the standard…
Xtlogit correctly predictedDear stat users, I am interested in calculating the correctly called event, false alrams, specifity…
Interpretation of outputDear all, I just started using STATA hence I need help in interpreting an output. Is the P-value in…
Better looking window (resolution)Dear all, I was wondering if there is a way to increase the resolution of the whole Stata screen, i…
Are there any assumptions for npregress?Hi, I am working on an abstract. I want to build model for continuous outcome variable (not normall…
Subscribe to:
Post Comments (Atom)
0 Response to loops
Post a Comment