Announcement

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

  • Comparing two slopes - nonlinear regression with repeated measures

    I'm unable to figure out which statistical procedure to use for comparing two slopes. I am using Stata 12.1 for Windows, but a solution for Stata 13 for Windows (or R) would be fine as well.

    For each person in my sample, I have one independent variable (age) and two dependent variables (self rating and peer rating). The relationship between age and the dependent variables ist most likely not linear. My aim is to figure out whether the slopes for the two regressions (age & self rating; age & peer rating) are statistically different from each other. How do I factor in the dependency between self- and peer-rating?

    I've spent some hours googling the problem, but wasn't able to phrase my objective clear enough to find useful answers for this problem. Thanks a lot in advance for your help!

  • #2
    If the relationship is not linear, you could try the nonlinear seemingly unrelated regression and after that perform a nonlinear hypothesis test. You do this with the nlsur and testnl commands respectively. As usual, you can follow Stata's help and/or manual on this commands in order to use the correct syntax. Hope this helps.

    Best regards,
    Carlos

    Comment


    • #3
      The non-linearity Julia refers to does not have to be in the parameters: she could just add age as splines or polynomials making these models linear in the parameters. In that case she can just use mvreg, followed by test.
      ---------------------------------
      Maarten L. Buis
      University of Konstanz
      Department of history and sociology
      box 40
      78457 Konstanz
      Germany
      http://www.maartenbuis.nl
      ---------------------------------

      Comment


      • #4
        If the relationship between a predictor and an outcome is non-linear, then there is no such thing as "the slope." It's a bit like asking which of two trout has bigger antlers! So you need to re-conceptualize your question before you can even start to think about choosing a statistical procedure.

        What kind of non-linearity do you think is in force here? Can you linearize by transforming (log, sqrt, arcin, whatever) one or some of the variables? If so you might then be able to contrast slopes of those relationships. If that won't work, perhaps the relationships are more or less continuous but piecewise linear and you can fit linear spline relationships with the same join points to both outcomes, and then you can contrast the slopes in corresponding segments of the spline (which may lead to concluding that one outcome has the steeper slope at young ages and the other has a steeper slope at older ages)?

        But if the non-linearity is radically different in the two outcomes, say, one has a cubic relationship to age and the other is high period sinusoidal, then I don't think there is any meaningful way to cast your question.

        Hope this helps.

        Comment


        • #5
          Sorry for that long run-on sentence in the second paragraph. Also, I meant "high frequency" sinusoidal, not "high period." Should have waited till I got more caffeine in before posting.

          Comment


          • #6
            Thanks everybody for your great and prompt answers! I was able to perform the test I was orginally thinking about simply using the mvreg command. The relationsships between age and the two outcome variable seem to be cubic.
            However, I will try to compare segments the way Clyde suggested and see whether this leads to results that are easier to interpret. Thanks again for your help and have a nice sunday.

            Comment

            Working...
            X