Hi Statalist,
I would like to test the significance of the indirect effect of multiple mediators. To obtain bootstrap standard errors and confidence intervals of the indirect effect, I used a re-adaptation of the instruction provided in UCLA (cf. webpage https://stats.idre.ucla.edu/stata/fa...tors-in-stata/), but kept recieving "invalid syntax error" message from stata. The syntax I used is as follows:
capture program drop bootmm
program bootmm, rclass
syntax [if] [in]
mi estimate, cmdok: sureg (AdjConMean_SEM EFI AdjConMean_Literacy AdjConMean_Gender AdjConMean_Presparty AdjConMean_Preseth) (AdjConMean_NAB AdjConMean_SEM EFI AdjConMean_Apathy AdjConMean_EDUC AdjConMean_Ngo_Civilso AdjConMean_Age)(GovPerformance AdjConMean_NAB AdjConMean_SEM EFI IQI Country_size GNI) if `in'
return scalar ind_eff = [AdjConMean_SEM]_b[EFI]*[AdjConMean_NAB]_b[AdjConMean_SEM]*[GovPerformance]_b[AdjConMean_NAB]
end
bootstrap r(ind_eff), bca reps(5000): bootmm
Could someone please help me with the correct syntax?
Best,
Ikenna
Related Posts with Bootstraping after "mi estimate, cmdok: sureg"
Comparing coefficients across DRsI run doubly robust regressions after running PSMatch2 on two different samples. I would like to com…
How to rename multiple variablesHi, I tried to rename many variables in the following way, but it doesn't seem to work. Code: renam…
Capturing the Return Code from an External ProgramI have an ado file that calls an external binary executable. Is there any way to capture the return …
Using parallel command with competing risk modelDear Statalisters, I would like to use parallel command with stcrreg. However, I cannot access to s…
log dependent variable and % independent variableHello Statalisters, I probably have an easy to answer question. However, I couldn't find the answer…
Subscribe to:
Post Comments (Atom)
0 Response to Bootstraping after "mi estimate, cmdok: sureg"
Post a Comment