Announcement

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

  • Doing a Joint test in xtmixed and interpreting the difference between output from contrast and xtmixed

    Dear STATALIST

    In my data I wish to evaluate if there is any difference between a variaty of hearing thresholds on different frequencies and gender.
    My question is how do I do a joint test instead of looking at variables individually? I get three different results when using Xtmixed, contrast sex#freq and contrast sex@freq.
    What are the differences in these tests?
    Thanks



    Click image for larger version

Name:	STATALIST.PNG
Views:	1
Size:	27.0 KB
ID:	1421553

  • #2
    The first tests difference in z between the two sexes at ("@") each of the frequencies. ("Simple [main] effects" as the command's help file says.) Their joint test is that all of the simple effects (all six) are zero.

    The second is the test of the interaction of sex and frequency. It is what you get in a factorial ANOVA table for the interaction term's F statistic and p-value.

    The last is a test of the whole model, including the random effect of patient, and not only the fixed effects (as in the the first two).

    Comment


    • #3
      Originally posted by Joseph Coveney View Post
      The first tests difference in z between the two sexes at ("@") each of the frequencies. ("Simple [main] effects" as the command's help file says.) Their joint test is that all of the simple effects (all six) are zero.

      The second is the test of the interaction of sex and frequency. It is what you get in a factorial ANOVA table for the interaction term's F statistic and p-value.

      The last is a test of the whole model, including the random effect of patient, and not only the fixed effects (as in the the first two).
      Thank you very much. This has been helpful.
      However I do not quite follow "Their joint test is that all of the simple effects (all six) are zero". Does this mean that there is no difference in Z-scores between the two sexes at different frequencies? The P value is highly significant should that not indicate the opposite? That there is a difference?

      EDIT:
      Or perhaps what you mean is that the joint test is a test that assesses weather all the parameters have zero difference? Thus it being significant indicates that there is a difference between each frequency depending on sex.
      Last edited by Puriya Daniel Yazdanfard; 09 Dec 2017, 17:29.

      Comment


      • #4
        Originally posted by Puriya Daniel Yazdanfard View Post
        I do not quite follow "Their joint test is that all of the simple effects (all six) are zero". Does this mean that there is no difference in Z-scores between the two sexes at different frequencies?
        It's like the joint test shown below. Look at what the component null hypotheses are for the joint test statistic that's shown below.


        .ÿquietlyÿsysuseÿauto

        .ÿquietlyÿmvregÿpriceÿmpgÿheadroomÿtrunkÿweightÿlengthÿ=ÿi.foreign

        .ÿquietlyÿtestÿ[price]1.foreign

        .ÿquietlyÿtestÿ[mpg]1.foreign,ÿaccumulate

        .ÿquietlyÿtestÿ[headroom]1.foreign,ÿaccumulate

        .ÿquietlyÿtestÿ[trunk]1.foreign,ÿaccumulate

        .ÿquietlyÿtestÿ[weight]1.foreign,ÿaccumulate

        .ÿtestÿ[length]1.foreign,ÿaccumulate

        ÿ(ÿ1)ÿÿ[price]1.foreignÿ=ÿ0
        ÿ(ÿ2)ÿÿ[mpg]1.foreignÿ=ÿ0
        ÿ(ÿ3)ÿÿ[headroom]1.foreignÿ=ÿ0
        ÿ(ÿ4)ÿÿ[trunk]1.foreignÿ=ÿ0
        ÿ(ÿ5)ÿÿ[weight]1.foreignÿ=ÿ0
        ÿ(ÿ6)ÿÿ[length]1.foreignÿ=ÿ0

        ÿÿÿÿÿÿÿF(ÿÿ6,ÿÿÿÿ72)ÿ=ÿÿÿ15.64
        ÿÿÿÿÿÿÿÿÿÿÿÿProbÿ>ÿFÿ=ÿÿÿÿ0.0000

        .ÿexit

        endÿofÿdo-file


        .ÿ

        Comment

        Working...
        X