Announcement

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

  • xtmixed for longitudinal multivariable regression

    Dear all,
    this is my first post on this forum.

    briefly: in a longitudinal within-subject clinical trial, I have some baseline variables (factors of a depression rating scale), and I would like to explore how they affect the decrease in my response variable (the total score of the same rating scale), in order to assess the best "clinical profile" predicting the response to such treatment.

    my syntax:

    reshape long yvar , i(id) j(time)
    xtset id time
    xtmixed yvar x1 x2 x3 x4 x5 x6 || id:, mle vce(robust)

    my doubt is: should I look for interaction with time? I have tried something like

    xtmixed yvar c.time##c.x1 || id:

    but I would not know how to adjust each xvar for the others.

    thanks in advance

  • #2
    Different models have different meanings and are appropriate for different research hypotheses. Your statement of the research question is too vague to provide an answer to your question. Please give a precise statement of your research hypothesis to make it possible to figure out what model would best accomplish your goals.

    Comment


    • #3
      thanks for your reply. extending my research question: we have a cohort of patients that underwent a treatment (same treatment for all f the cohort). we have no placebo control group. the outcome variable is clinical response (change in clinical severity score from before to after treatment, 2 timepoints). the independent variables are 6 factors (collected before treatment) derived from a factor analysis of the same rating scale used to assess clinical severity.
      I would like to know how each factor (indepvar) affects/predicts the change in my outcomevar. we also have a number of potential confounders that I would like to insert in the model.

      Please ask for any further detail.

      Comment


      • #4
        Well, since you want to model your 6 x variables as predictors of the change from before to after treatment, I would think along the lines of

        Code:
        mixed y i.time##c.(x1 x2 x3 x4 x5 x6) other_covariates_you_want  || id:
        The interaction term coefficients will estimate the expected difference between y pre- and post- treatment associated with a unit difference in the x variable.

        Notes: the -xtmixed- command has been renamed -mixed-. Stata still recognizes the older name, but the use of -mixed- is preferred. You do not need to -xtset- your data to use -mixed- (nor to use it under its previous name -xtmixed-), though neither is any harm done by it. Your time variable is clearly discrete, even dichotomous, so it should be entered as i.time, not c.time in any model.

        Comment


        • #5
          Thank you very much, extremely clear answer. Now, in the equation you posted it looks like we are adjusting the effect-over-time (i.e. the interaction term i.time##c.xvar , if I understood correctly) of each x var for the effect-over-time of the other x vars. Do you think it would be more appropriate to adjust the effect-over-time of each factor for the baseline value of each other factor? In this case, should I run a series of LMM? like:

          Code:
          mixed y i.time##c.x1 x2 x3 x4 x5 x6 other_covariates_you_want || id:
          mixed y x1 i.time##c.x2 x3 x4 x5 x6 other_covariates_you_want || id:
          mixed y x1 x2 i.time##c.x3 x4 x5 x6 other_covariates_you_want || id:
          mixed y x1 x2 x3 i.time##c.x4 x5 x6 other_covariates_you_want || id:
          etc..

          thanks again for your attention

          Comment


          • #6
            we are adjusting the effect-over-time (i.e. the interaction term i.time##c.xvar , if I understood correctly) of each x var for the effect-over-time of the other x vars
            No, that's not right. The ## operator causes Stata to include not just the interaction terms but the corresponding main effects. So after Stata fully expands it, the code I proposed will include adjustments for x1, x2, ..., x6, as well as for the time#x1, time#x2,...time#x2 terms. The models you propose in #5 are an alternative approach that may be reasonable. I think it is more a matter of the clinical substance and the specific research question than any statistical considerations as to which is more reasonable, that or the single model with all of the interactions entered simultaneously. From a generic perspective, if I understand the nature of these variables correctly, it is not possible to change any of the x's independently of the others, so I would think the all interactions simultaneously model makes more sense, but if the x's can vary close to independently, or if several of the interaction terms turn out to be small, then this would be less of a consideration and the results of separate models might be more understandable. Again, much depends on a very precise formulation of your research hypothesis.
            Last edited by Clyde Schechter; 08 Mar 2016, 12:03. Reason: Correct copy/paste error in quote block.

            Comment


            • #7
              I understand your explaination. These variables are derived from a factor analysis, hence they should display a certain degree of mutual independence..but I think this matter goes off topic. Your explaination on the difference between the two modeling approach is extremely clear.

              Thank you very much!

              Comment

              Working...
              X