MHB Can Categorical Variables be Used in Multiple Regression Models?

  • Thread starter Thread starter smp
  • Start date Start date
  • Tags Tags
    Model Regression
Click For Summary
Categorical variables cannot be directly included in multiple regression models as they are not quantitative. In the discussed regression model, the dependent variable Y (grams of seed) can include continuous predictors such as the number of fruit and field number, but not categorical variables like type of fruit. To incorporate categorical data, one must convert it into a numerical format, typically through techniques like dummy coding. The inability to mix categorical and continuous variables directly in the regression setup is a key point. Properly preparing the data is essential for accurate analysis in regression modeling.
smp
Messages
1
Reaction score
0
Hello, I am trying to do the following regression model;

Y = N + T + F + NT + NF + NTF + error

Y= Grams of seed
N= Number of fruit
T= Type of fruit (2 types, alpha)
F= Field number (3)

I have tried putting this in MiniTab and I can't get this set up correctly.
Assistant> Regression> Multiple Regression

Y= Grams of Seed

Continuous X Variable= Number of Fruit, Field Number - but I can't select Type since they are words and not numbers. .

Categorical X value is optional- should I put Type here?

Thank You
 
Physics news on Phys.org
Hi smp, welcome to MHB!

This looks like a trick question.
We can indeed not add a type and number together. That is, it is not possible to evaluate something like "apple" + 2.
More generally, a multiple linear regression requires that all variables are quatitative (interval or ratio). That excludes categorical.
 
First trick I learned this one a long time ago and have used it to entertain and amuse young kids. Ask your friend to write down a three-digit number without showing it to you. Then ask him or her to rearrange the digits to form a new three-digit number. After that, write whichever is the larger number above the other number, and then subtract the smaller from the larger, making sure that you don't see any of the numbers. Then ask the young "victim" to tell you any two of the digits of the...

Similar threads

  • · Replies 6 ·
Replies
6
Views
3K
  • · Replies 23 ·
Replies
23
Views
4K
  • · Replies 30 ·
2
Replies
30
Views
4K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 8 ·
Replies
8
Views
2K
Replies
26
Views
3K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 7 ·
Replies
7
Views
2K
  • · Replies 1 ·
Replies
1
Views
1K
  • · Replies 7 ·
Replies
7
Views
4K