MHB Can Categorical Variables be Used in Multiple Regression Models?

  • Thread starter Thread starter smp
  • Start date Start date
  • Tags Tags
    Model Regression
AI Thread 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.
 

Similar threads

Back
Top