+ Reply to Thread
Results 1 to 3 of 3

Thread: Linear piecewise spline interpretation

  1. #1
    Points: 28, Level: 1
    Level completed: 56%, Points required for next Level: 22

    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Linear piecewise spline interpretation




    Hello,

    I suspected my data was non-linear so I ran PROC GAM to visualize my age variable relative to my binomial outcome. I realize adding one spline knot at age 51.5 was very appropriate. I created the linear piecewise spline using a "relative reference" coding scheme:

    if age<=51.5 then age515=0;
    else age515=age-51.5;


    Next I ran a log binomial regressionPROC GENMOD; dist=bin, link=log) as my outcome variable is very prevalence (>60%). I have the outputs that give me the prevalence ratios for the first regression line up to age <=51.5; how do I get the prevalence ratios for the second regression line >51.5? I have one class variable (four levels) and one continuous variable

    From the output:
    Analysis Of Maximum Likelihood Parameter Estimates
    Parameter Beta
    Intercept -2.3315
    Age (contin) 0.0328
    Var (level 4) 0.6515
    Var (level 2) 0.6509
    Var (level 3) 0.6515
    Var (level 1) 0.0000




    Thanks

  2. #2
    Omega Contributor
    Points: 38,326, Level: 100
    Level completed: 0%, Points required for next Level: 0
    hlsmith's Avatar
    Location
    Not Ames, IA
    Posts
    6,995
    Thanks
    398
    Thanked 1,185 Times in 1,146 Posts

    Re: Linear piecewise spline interpretation

    I have not done these procedures myself, so I am not much help in that regard. But I know there are some macros (spline), that address visualizing this process and provide the odds ratios for all values above and below the compared reference group.
    Stop cowardice, ban guns!

  3. #3
    Points: 28, Level: 1
    Level completed: 56%, Points required for next Level: 22

    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Linear piecewise spline interpretation


    Let me rephrase the question:

    The age continuous term has two separate betas, a ratio estimate before the spline knot (eg 1.0333 per 1 year increase), and a beta/ ratio estimate after the spline knot (eg PR=0.9844 per 1 year increase).

    Say if I include a CLASS variable "monthsexchangingquartiles" that has 4 levels, SAS tells me the ratios are static (the same) before and after the spline knot. Am I suppose to get the same ratios before and after a linear piecewise spline with one knot? Or am I suppose to expect separate ratios for the CLASS term after the spline knot?

+ 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