Hi everyone. I need to make bootstrap for regression paramatr for price and weight in new sample from general population, but i don't know how to make regression in new sample.
My code looks:
sample
preserve
local var1 = "price"
local var2 = "weight"
local n=r(N)
local B=1000
local alfa = 0.05 //b to liczba próbek
forvalues i=1/`B'{
generate sampl`i'=`var1'[ceil(`n'*runiform())]
generate sampl1`i'=`var2'[ceil(`n'*runiform())]
reg var1 var 2
}
Can you help me ?
Related Posts with Bootstrap for regression parametrs
Saving part of a datasetHi, I have 33 variables and 1000 participants. The 33rd variable has 20 participants with data enter…
Command for matching*across*a dummy-variable?Dear Statalisters, I want to match (pscores of) observations across pre- and post-intervention. Thi…
Removing the line below each headingDear Stata users, I have drawn a combined graph as below and would like to remove the line below ea…
Splitting string into column vectorDear Statalist, I am currently working with a dataset consisting of research articles, where a give…
Unbalanced panel with xtregHello I am using unbalanced panel for the first time. I would like to know if it is possible to use …
Subscribe to:
Post Comments (Atom)
0 Response to Bootstrap for regression parametrs
Post a Comment