Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • serial causal mediation analysis in STATA19 with binary outcome, binary exposure (treatment) variable and two mediator

    Dear all,
    I am using StataNow 19 for causal mediation analysis. I have a binary outcome, a binary exposure (treatment) variable, and two mediators—one continuous and one binary—while adjusting for other baseline covariates.

    The analysis produces effect estimates reported as coefficients. However, the Stata command does not allow me to specify the model type. Could you please advise whether it would be appropriate to report the effect estimates as coefficients in this setting?

    Thank you in advance for your guidance.
    Asish Subedi

  • #2
    Please read the Forum's FAQ. Your question lacks essential information (see FAQ, #12) to properly assist you.

    Comment


    • #3
      Dear Drik and Statalist members,

      I am conducting a serial causal mediation analysis using Stata 19 (latest version) with CPSP_6MONTH as the binary outcome, INTRAOP_PAIN as the binary treatment, MAXPAIN_72HRS (continuous) and postdepression_11cat (binary) as serial mediators, and covariates including Age, predepression_11cat, previous_cs, ANX_preop, and HO_OTHERCHRON_PAIN. I have provided the sample data, STATA command and output below. The effect estimates are in coefficient. Is the command correct and how to report them. Thank you in advance.
      ----------------------- copy starting from the next line -----------------------
      Code:
      * Example generated by -dataex-. For more info, type help dataex
      clear
      input byte(CPSP_6MONTH AGE predepression_11cat previous_cs ANX_preop HO_OTHERCHRON_PAIN INTRAOP_PAIN MAXPAIN_72HRS postdepression_11cat)
      0 31 0 0 4 0 0 5 0
      0 26 0 0 4 0 0 5 0
      0 24 0 0 2 0 0 6 0
      0 24 0 0 4 0 0 3 0
      0 26 0 1 2 0 0 3 0
      0 38 0 1 0 0 0 4 0
      0 30 0 0 3 0 0 3 0
      0 24 0 1 1 0 0 3 0
      1 24 0 1 4 0 1 6 0
      0 20 0 0 2 0 0 4 0
      1 23 0 0 3 0 1 5 0
      0 35 0 0 2 0 0 4 0
      0 36 0 1 0 0 0 5 0
      0 29 0 0 2 0 0 3 0
      0 36 0 1 4 1 0 5 0
      1 33 0 0 0 0 1 6 0
      0 30 0 0 3 0 0 4 0
      0 24 0 1 0 0 0 5 0
      0 20 0 0 2 0 0 3 0
      0 30 0 1 2 0 0 4 0
      0 34 0 0 2 0 0 3 0
      0 36 0 1 2 0 0 3 0
      0 33 0 1 2 0 0 5 0
      1 24 0 1 2 0 1 6 0
      0 24 0 0 2 0 0 6 0
      0 23 0 0 0 0 0 3 0
      0 21 1 0 3 0 0 3 0
      0 24 0 0 4 1 0 4 0
      0 32 0 1 0 0 0 3 0
      0 34 0 1 3 0 0 3 0
      0 27 0 1 0 0 0 5 0
      0 20 0 0 4 0 0 3 0
      0 21 0 1 0 0 0 3 0
      1 24 0 0 3 0 0 6 0
      0 27 0 0 3 0 0 3 0
      0 22 1 1 4 0 0 4 0
      0 28 0 1 0 0 0 3 0
      0 22 0 0 3 0 0 3 0
      1 23 0 0 0 0 1 6 0
      0 31 0 1 0 0 0 3 0
      0 20 0 0 5 0 0 4 0
      0 26 0 1 0 0 0 4 0
      0 33 0 0 0 0 0 4 0
      0 28 0 0 4 0 0 4 0
      1 27 0 0 0 0 0 7 0
      0 35 0 0 3 0 0 3 0
      0 34 0 1 0 0 0 4 0
      0 29 0 0 5 0 0 3 0
      0 34 0 1 0 0 0 3 0
      0 30 0 1 5 0 0 3 0
      0 29 0 0 5 0 0 5 0
      0 34 1 0 4 0 0 3 0
      1 29 0 0 3 0 1 6 0
      0 20 0 1 0 0 0 4 0
      0 31 0 0 0 0 0 5 0
      1 28 0 1 0 0 1 7 0
      0 34 0 1 0 1 0 3 0
      0 31 0 0 0 0 0 4 0
      0 31 0 0 0 0 0 3 0
      0 25 0 0 4 0 0 3 0
      1 31 1 0 4 0 1 5 0
      0 27 0 0 4 0 0 3 0
      0 35 0 0 3 0 0 4 0
      0 25 0 1 3 0 0 4 0
      0 31 0 0 4 0 0 4 0
      0 31 0 0 0 0 0 3 0
      1 20 0 0 5 0 1 5 0
      0 25 0 0 3 0 0 2 0
      0 20 0 0 3 0 0 4 0
      0 36 0 0 0 0 0 3 0
      0 25 0 0 3 0 0 3 0
      0 35 0 0 0 0 0 3 0
      0 30 0 1 2 0 0 3 0
      0 29 0 1 4 0 0 4 0
      0 24 0 1 3 1 0 3 0
      1 26 0 0 0 0 1 6 0
      0 22 0 0 3 0 0 4 0
      0 32 0 0 2 0 0 3 0
      0 35 0 1 0 0 0 4 0
      0 31 0 0 0 0 0 3 0
      0 27 0 1 0 0 0 6 0
      0 28 1 0 4 0 0 4 0
      0 34 0 1 0 1 0 3 0
      0 25 0 1 4 0 0 3 0
      0 22 1 0 4 0 0 4 0
      1 20 1 0 5 0 0 4 0
      0 36 0 1 4 0 0 6 0
      0 23 1 0 4 0 0 4 0
      0 25 1 1 6 0 0 3 0
      0 20 0 0 0 0 0 4 0
      0 28 0 0 2 0 0 3 0
      1 30 1 0 4 0 0 5 1
      0 23 1 0 6 0 0 3 0
      0 28 0 1 5 0 0 3 1
      0 24 1 0 6 0 0 4 0
      0 34 0 0 0 0 0 3 0
      1 24 0 0 3 0 1 6 1
      0 34 0 0 0 0 0 5 0
      0 29 0 0 5 0 0 3 0
      0 24 1 0 7 0 1 5 1
      end
      ------------------ copy up to and including the previous line -----------------
      Code:
      mediate (CPSP_6MONTH AGE ANX_preop previous_cs HO_OTHERCHRON_PAIN predepression_11cat) (postdepression_11cat AGE ANX_preop previous_cs HO_OTHERCHRON_PAIN predepression_11cat)(MAXPAIN_72HRS AGE ANX_preop previous_cs HO_OTHERCHRON_PAIN predepression_11cat)  (INTRAOP_PAIN), sequential
      Code:
      Iteration 0:  EE criterion = 1.903e-30  
      Iteration 1:  EE criterion = 1.652e-32  
      
      Causal mediation analysis                                  Number of obs = 414
      
      Mediation type: Sequential
      Mediator 1:     MAXPAIN_72HRS
      Mediator 2:     postdepression_11cat
      Treatment type: Binary
      ------------------------------------------------------------------------------
                   |               Robust
       CPSP_6MONTH | Coefficient  std. err.      z    P>|z|     [95% conf. interval]
      -------------+----------------------------------------------------------------
      NDE          |
      INTRAOP_PAIN |
         (1 vs 0)  |   .5035293   .0899528     5.60   0.000      .327225    .6798336
      -------------+----------------------------------------------------------------
      NIE1         |
      INTRAOP_PAIN |
         (1 vs 0)  |   .2619934    .042842     6.12   0.000     .1780246    .3459621
      -------------+----------------------------------------------------------------
      NIE2         |
      INTRAOP_PAIN |
         (1 vs 0)  |   .0100538   .0087244     1.15   0.249    -.0070458    .0271534
      -------------+----------------------------------------------------------------
      NIE12        |
      INTRAOP_PAIN |
         (1 vs 0)  |   .0003361   .0025085     0.13   0.893    -.0045805    .0052528
      -------------+----------------------------------------------------------------
      TE           |
      INTRAOP_PAIN |
         (1 vs 0)  |   .7759126   .0757626    10.24   0.000     .6274207    .9244046
      ------------------------------------------------------------------------------

      Comment


      • #4
        I can't judge whether you specified the model correctly. But reading the manual there is a section "Example 6: Causal mediation model with a binary mediator and binary outcome" with an explicit specification of logit models. Following this my intuition tells me that exponentiated coefficients can be interpreted as odds ratios. For this it should be possible to use -esttab- (from the SSC package -estout-) as a "postestimation" command, e.g.
        Code:
        esttab, eform
        . Something along this line should also be possible for serial mediation analysis (of which I am no expert).

        Comment

        Working...
        X