Hello there,
Got a question. I am working on a panel data and I am trying to find the mean of some variables, by village groups. The data ranges from year 2008 to 2018 for each village group. I have tried to use -collapse- but I have not been successful. I have read the reason for this in one of the statalist posts on the same problem. Unfortunately, I am unable to figure out any other way of achieving my goal. Currently, the command is as follows:
xtset gpid year
local name3 "jcissue jc_sc jc_st jc_gen personwrk_allot hh_wrkd person_wrkd schh_wrkd sthh_wrkd persondgen_wrkd scpersond_wrkd stpersond_wrkd wpersond_wrkd persond labexp_disb matexp_disb labexp_dp matexp_dp"
foreach name3 in jcissue jc_sc jc_st jc_gen personwrk_allot hh_wrkd ///
person_wrkd schh_wrkd sthh_wrkd persondgen_wrkd scpersond_wrkd ///
stpersond_wrkd wpersond_wrkd persond labexp_disb matexp_disb ///
labexp_dp matexp_dp {
}
I really don't know how I should continue after this? Kindly help.
Related Posts with Finding mean in a loop
How to get the same point estimate using ivreg2 and xtabond2 with a constant termDear all, I am writing a project using IV as my main strategy, and I want to use a dynamic panel as…
"variable e not found" message from -describe-I don't understand why I'm getting the message Code: variable e not found r(111); when I run the c…
Error message "outcome does not vary; remember 0=negative outcome, all other nonmissing values=positive outcome"Hello, I have a binary variable that I called SRI. This variable equals 1 if an investor invests in…
Help interepreting the results of sem/medsem mediation analysis toolsHello everyone, I have a doubt interpreting the results obtained when using the sem/medsem commands…
Repeated time values within panelHello, I am trying to set a panel data but I keep getting this message: Code: . xtset id year repea…
Subscribe to:
Post Comments (Atom)
0 Response to Finding mean in a loop
Post a Comment