BookmarkSubscribeRSS Feed
yasyuki_k
Calcite | Level 5

Hi, experts!

I need your help about GAM procedure.

If I use the ADDITIVE suboption with class statement to get the additive component plots, estimates for the plots aren't reasonable.

Is there any solution?

proc gam data=dataset plots=component(additive);

     class x0;

     model  y= param(x0) spline(x1) spline(x2) / link=Identity  dist=normal method=GCV;

run;

3 REPLIES 3
SteveDenham
Jade | Level 19

What do you mean that the plots aren't reasonable?  Can you give an example of what happens, and what you would expect?

Steve Denham

yasyuki_k
Calcite | Level 5

When model only included continuous variable,

estimates of additive component in the data from ods output SmoothingComponentPlot were like left table.

On the other hand, when model  include categorical variable,  estimates were like right table.

cont.PNGcat.PNG

SteveDenham
Jade | Level 19

It appears that the right hand column is giving the difference from the reference level of x0, which in the default case would be the last level.  Perhaps you could add the value of the last level (or its mean/median if the class collapses several values) to get values more like those on the left.

Steve Denham

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

What is ANOVA?

ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 3 replies
  • 1461 views
  • 3 likes
  • 2 in conversation