Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
st: AW: Simulate stepwise: Report coefficients from each replication
From
"Martin Weiss" <[email protected]>
To
<[email protected]>
Subject
st: AW: Simulate stepwise: Report coefficients from each replication
Date
Mon, 29 Mar 2010 17:02:22 +0200
<>
Where exactly do you define -program- "sim"? -simulate- expects a command
after the colon, remember...
HTH
Martin
-----Ursprüngliche Nachricht-----
Von: [email protected]
[mailto:[email protected]] Im Auftrag von John Antonakis
Gesendet: Montag, 29. März 2010 16:56
An: [email protected]
Betreff: st: Simulate stepwise: Report coefficients from each replication
I want to highlight the evils of stepwise analysis. However, I am having
problems in getting Stata to report the coefficients from each
replication --it seems that it only reports the coefficients that are
common across replications. Anyone have any ideas?
clear
set seed 51
drop _all
set obs 272
gen x1=rnormal()
gen x2=rnormal() +.2*x1
gen x3=rnormal() +.3*x1 + .3*x2
gen x4=rnormal() +.2*x1
gen x5=rnormal()
gen x6=rnormal() + .2*x5
gen x7=rnormal() + .5*x5
gen x8=rnormal() + .1*x7
gen x9=rnormal() + .1*x7
generate double e = 5*rnormal()
generate double u = sqrt(exp(-2+0.6*x1))*e
gen y = 5+ x1+x2+x3+x4+x5+x6+x7+x8+x9 + 2*u
stepwise, pr(.2): reg y x1-x9
end
simulate _b _se, reps(20) seed (123) : sim,
--
____________________________________________________
Prof. John Antonakis, Associate Dean
Faculty of Business and Economics
Department of Organizational Behavior
University of Lausanne
Internef #618
CH-1015 Lausanne-Dorigny
Switzerland
Tel ++41 (0)21 692-3438
Fax ++41 (0)21 692-3305
Faculty page:
http://www.hec.unil.ch/people/jantonakis
Personal page:
http://www.hec.unil.ch/jantonakis
____________________________________________________
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/