# regression models with mixed types of independent variables

#### winecoding

##### New Member
I am working on building a forecasting model, the independent variables are grouped into three types: some variables are continuous; some variables are ordinal; while some variables are nominal. The dependent variable is continuous.
Can the normal multiple regression model handle this kind of scenario? Besides that, are there any other models that deserves a try?

#### Karabiner

##### TS Contributor
You must dummy-code the ordinal and categorical variables
before entering into the regression equation. Maybe you
want to do a little web search how this is done properly.
The main thing is to compute k-1 dummy variables for
a variable with k levels (1 reference level is left out).

With kind regards

K.

#### winecoding

##### New Member
Karabiner, thanks for your answer. For categorical values, it is mainly related to coding issues. For the ordinal variables, how to treat it? We use the same coding techniques. It looks like that then we just lost a lot of information. Thanks.

You must dummy-code the ordinal and categorical variables
before entering into the regression equation. Maybe you
want to do a little web search how this is done properly.
The main thing is to compute k-1 dummy variables for
a variable with k levels (1 reference level is left out).

With kind regards

K.

#### Injektilo

##### New Member
I'm not understanding the question in your last post. Karabiner's answer still applies. Treat each possible level in your ordinal/categorical variables as a binomial variable (0=Not that level, 1=That level), and remove one of the variables to avoid linear dependency.

#### winecoding

##### New Member
Hi Injektilo,

Looks like to me that this coding scheme treat categorical and ordinal variable in the same way. However, there is an internal relationship existing in the ordinal variables, like 1<2<3, which is kind of different with a categorical variable of {a, b, c}. Will treating them the same way cause the information lost? Thanks.

I'm not understanding the question in your last post. Karabiner's answer still applies. Treat each possible level in your ordinal/categorical variables as a binomial variable (0=Not that level, 1=That level), and remove one of the variables to avoid linear dependency.

#### Karabiner

##### TS Contributor
Sadly, you either have to waste some information by using dummies,
or to leave the variable out completely.

With kind regards

K.

#### Injektilo

##### New Member
winecoding,

As long as you properly label each of your dummy variables for the ordinal variable (Q1_first, Q1_second, etc.), you should be able to make sense of the results. The only information inherent in ordinal variables is that you know there is an order through the levels, but you don't know the distance between each level. This remains the case after you manipulated the variables.