+ Reply to Thread
Results 1 to 5 of 5

Thread: Linear Mixed Model Analysis with multiple fixed factors

  1. #1
    Points: 391, Level: 7
    Level completed: 82%, Points required for next Level: 9

    Posts
    4
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Linear Mixed Model Analysis with multiple fixed factors




    Hellow,

    Here is a question on linear mixed model analysis for an intervention

    The study composed of two group of subjects who receive a DrugA versus Placebo and their Cholestrol and Sugars measured at baseline, six months and 12 months.

    So i did a simple analysis to detect the changes with time and drugA using nlme in R


    model1 = lme(Cholesterol~Time+Group,random=~1|Patient_id) where Time and Group are fixed and PatientID is random

    and for Sugar,

    model2 = lme(Sugar~Time+Group,random=~1|Patient_id)


    I got a significant change with time and Group in Cholesterol


    But the same subjects were also receiving some other drugs (B,C and D) in such a manner that some of them receive all(A,B and C) while some receive A &B and so on!

    What will be the best way to explore for e.g those who received drug B showed a response to DrugA where as the rest wont?


    Thanks in advance


    Here is a snapshot of variables (attached)
    Attached Images  

  2. #2
    Points: 391, Level: 7
    Level completed: 82%, Points required for next Level: 9

    Posts
    4
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: Linear Mixed Model Analysis with multiple fixed factors

    sorry to bump, no answers! kindly let me know if something is missing/unclear in the post. Thanks in advance

  3. #3
    Points: 3,882, Level: 39
    Level completed: 55%, Points required for next Level: 68

    Posts
    47
    Thanks
    2
    Thanked 13 Times in 13 Posts

    Re: Linear Mixed Model Analysis with multiple fixed factors

    Quote Originally Posted by risu View Post
    But the same subjects were also receiving some other drugs (B,C and D) in such a manner that some of them receive all(A,B and C) while some receive A &B and so on!

    What will be the best way to explore for e.g those who received drug B showed a response to DrugA where as the rest wont?
    Hi risu,
    Why don't you add B, C, and D as additional independent variables to your model? That should adjust for their effects when evaluating drug A. Also, consider modeling the interaction between drug A and time to see if the association between drug A and cholesterol/sugar changes over time. Maybe the impact of drug A decreases over time?

  4. #4
    Points: 391, Level: 7
    Level completed: 82%, Points required for next Level: 9

    Posts
    4
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: Linear Mixed Model Analysis with multiple fixed factors

    Thanks mostater,

    Now i did like this ,

    modelA=lme(Cholesterol~Time+Group+drugB+drugC+drugD,random=~1|Patient_id,method="ML")
    modelB=lme(Cholesterol~Time*Group+drugB+drugC+drugD,random=~1|Patient_id,method="ML")


    anova(modelA,modelB)
    Model df AIC BIC logLik Test L.Ratio p-value
    modelA 1 13 174.1280 213.7761 -74.06401
    modelB 2 15 178.0266 223.7744 -74.01328 1 vs 2 0.1014577 0.9505


    Should i keep the interaction term? Now am getting the effect from drug B , C and D as well. Also can see the p-values from

    summary(modelA)$tTable

    Please confirm if am doing it right.

    Thanks again for the feedback

  5. #5
    Points: 3,882, Level: 39
    Level completed: 55%, Points required for next Level: 68

    Posts
    47
    Thanks
    2
    Thanked 13 Times in 13 Posts

    Re: Linear Mixed Model Analysis with multiple fixed factors


    Quote Originally Posted by risu View Post
    modelA=lme(Cholesterol~Time+Group+drugB+drugC+drugD,random=~1|Patient_id,method="ML")
    modelB=lme(Cholesterol~Time*Group+drugB+drugC+drugD,random=~1|Patient_id,method="ML")
    When you look at the interaction between time and group be sure to include the individual effects as well. I am not certain if the model B statement above does that or if it needs to be re-stated as follows:
    modelB=lme(Cholesterol~Time+Group+Time*Group+drugB+drugC+drugD,random=~1|Patient_id,method="ML")

    If the interaction term from this model is not significant, then you can drop it in favor of model A as you have it above, which is much simpler to interpret. If the interaction is significant, then I suggest you evaluate the group effect (on cholesterol/sugar) at each time point. If interaction exists, you should see the effect change over time. That is, the difference between treatment and placebo will vary across the 3 time points.

    Quote Originally Posted by risu View Post
    anova(modelA,modelB)
    Model df AIC BIC logLik Test L.Ratio p-value
    modelA 1 13 174.1280 213.7761 -74.06401
    modelB 2 15 178.0266 223.7744 -74.01328 1 vs 2 0.1014577 0.9505
    I am not sure what you are attempting to do here. Are you evaluating the residuals from each of the models to determine if they are different? I don't think this step is necessary. The AIC and BIC can be used to compare models. Regardless, I still recommend running the model with interaction as described above to determine whether it should remain in the model or not.

    Hope this helps!

  6. The Following User Says Thank You to mostater For This Useful Post:

    risu (03-06-2015)

+ Reply to Thread

           




Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts






Advertise on Talk Stats