BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
shahd
Quartz | Level 8

Hi all
I have a baseball data sets with 30 independent variables. In this data set, I have one variable which is a combination of the summation 3 variables from the data set. For example, x8=x3+x4+x5. I need to build a multiple linear regression model, if i include x8 in my model should i remove x3,x4,x5. Could you please advise with this

1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User

Depends on the data, I'd run both models and pick the one that does better. Consider x8 an engineered feature.

View solution in original post

8 REPLIES 8
Reeza
Super User
Yes you should.
shahd
Quartz | Level 8
What is the best choice to remove x8 or x3, x4,x5
Reeza
Super User

Depends on the data, I'd run both models and pick the one that does better. Consider x8 an engineered feature.

shahd
Quartz | Level 8
Thank you very much. This is very helpful. what if I have multiplication not addition should I follow the same procedure
Reeza
Super User
I would probably treat that as two variables and include an interaction term instead. Then if the interaction term isn't significant you would drop it. It's a non-linear relationship instead of linear in your first question. However, theoretically if you're model building you should be testing these things at the same time ie you have two different options for two sets of variables, so that means fitting 4 models and determine what's the best. Or three if you take my advice. Whatever you do, document it, and explain your decision making in your notes.
shahd
Quartz | Level 8
Thanks a lot.
I have another variable x9=(x1+x7+x8)/(x3+x4+x6) could you please advice with this
Reeza
Super User
Now I think you need to read up on feature engineering.
Reeza
Super User
Also, don’t know how much of this is made up, but you’ve mentioned three different features and they all overlap with calculations so you’ll need to factor that in as well. Basically if those were your actual variables and situation it’s more complex than originally you suggested.

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
  • 8 replies
  • 1343 views
  • 1 like
  • 2 in conversation