Choose Language Hide Translation Bar

## Why is the number of variables limited when using stepwise regression?

Hi everyone,

Disclaimer: I'm very new at using JMP so this could be a basic error. Even still, I'd appreciate help.

I've been trying to use stepwise regression fit model to see what effect single variables, two-factor variables, and quadratic variables have on the outcome variable. When I hit "enter all" after selecting backward direction, it will only add 13 variables, and I can't click on the checkboxes to add more. I want to be able to add all of the variables & interactions, but I can't add them. I think it has something to do with the degrees of freedom but I'm not sure. Grateful for any help. 1 ACCEPTED SOLUTION

Accepted Solutions
Solution

## Re: Why is the number of variables limited when using stepwise regression?

How many rows of data do you have?  I would have guessed you are right that the constraint is you can't exceed number of rows you have in the number of starting model terms because you will have non full rank matrix and you won't be able to estimate all the parameters.  In that case, you would have to do forward selection.  However, it looks like you have 28 degrees of freedom for error even with all those boxes checked, so that doesn't seem like the case.

-- Cameron Willden
5 REPLIES 5
Solution

## Re: Why is the number of variables limited when using stepwise regression?

How many rows of data do you have?  I would have guessed you are right that the constraint is you can't exceed number of rows you have in the number of starting model terms because you will have non full rank matrix and you won't be able to estimate all the parameters.  In that case, you would have to do forward selection.  However, it looks like you have 28 degrees of freedom for error even with all those boxes checked, so that doesn't seem like the case.

-- Cameron Willden
Highlighted

## Re: Why is the number of variables limited when using stepwise regression?

I have 41 complete rows of data.

## Re: Why is the number of variables limited when using stepwise regression?

How many observations do you have? Be sure to subtract number of excluded rows and rows with missing response?

Learn it once, use it forever!

## Re: Why is the number of variables limited when using stepwise regression?

I realized that I did not have enough data. Thanks for all the help, Mark

## Re: Why is the number of variables limited when using stepwise regression?

Back to basics!

Is this an observational study or a design experiment?

What is the distribution of the predictors and the response?

You might have many observations (number of rows) but what information do they provide?

Learn it once, use it forever!