I am working with a data set that has five implicate data sets. For each data set, I am running a regression. After these regressions are finished, I want to average the e() results and then store the averaged result. Below, is an example of what I mean, though I am sure my nomenclature is incorrect:
reg x y1 y2 y3 if rep = 1
reg x y1 y2 y3 if rep = 2 ...
reg x y1 y2 y3 if rep = 5
gen varz = average(e_y11, e_y12, e_y13, e_y14, e_y15)
(and then store varz, and display it through estout)
This is a simplified example of what I am trying to do, but if anyone has suggestions for the above, I can then apply it to my code. Thank you.
Related Posts with Averaging eclass commands across multiple models
multiple lines in one graph with if conditionshi statalist, I have the following data: Code: * Example generated by -dataex-. For more info, ty…
sureg compare COX time-to-event regression comparison between 2 groupsHi, first post, my mentor told me to run 'sureg' to compare my estimates from two COX regressions sp…
Reshaping Data and Variables for a Dynamic Panel Data AnalysisHi there, I am happy to be new in this forum and currently writing on a Panel Data Analysis for a co…
How can check the assumption for survival analysis with Schoenfeld residual method in Complex survey designHello, My data is the national health survey with a complex survey design. I want to analyse the as…
coefplot helpHi all, I am newer to Stata, using coefplot. Ive looked at coefplot help which has given me a good o…
Subscribe to:
Post Comments (Atom)
0 Response to Averaging eclass commands across multiple models
Post a Comment