# Dummy variables Changing Slope in MiniTab

Six Sigma – iSixSigma Forums Old Forums General Dummy variables Changing Slope in MiniTab

Viewing 5 posts - 1 through 5 (of 5 total)
• Author
Posts
• #52733

Lee
Participant

I want to do a regression in a data set that is strongly suspected of having a differnt slope on one variable, depending on the cooling unit that is performing a cooling.  My desire is to perform one stepwise regresssion to separate out the units (via dummy variable) and to reveal the estimated slope for each of the units.  I’m having a problem with the modeling.
As a verification step I generated some simple data to see if MT would do what I wanted.  I set Unit1 and Unit2 as dumy variables (i.e., as 0 and 1)
For Unit 2 I entered data a Temp=Time^2+1.0*Lb_loaded
For Unit 1 I entered data a Temp=Time^2+0.1*Lb_loaded
Not at all what I expected.   Am I doing something wrong, or can MT just not do what I wanted?  I wanted to process the data as a group so that the cofficient on Time is the same for all units – as expeced from the fundamental processes going on.

0
#185942

Robert Butler
Participant

I don’t see that you have a problem.  You have a separate equation for each unit, you plugged in a series of times and loadings to simulate temp output and then you ran a regression to predict temperature as a function of time, load, and unit and you got the final regression equation as noted in your post.
Other than the fact that running the regression in raw units as opposed to normalized units (units scaled from -1 to 1) will give you regression diagnostics indicating you can’t include the square term in the model the equation is what you would expect.  Temperature is temperature, Unit is either 0 or 1 therefore when it is 0 the unit term disappears and load is load.  The coefficient on temperature applies to the entire data set.
Try the following
Raw Data
2  2
4  2
8  2
2  6
4  6
8  6
Scale these numbers from -1 to 1 and form the squared term and the interaction and then run stepwise.  If you set your sls to .05 the reduced model will be
Temp = 29 -3.6*Unit +30*nTime +1.1*nLoad +9*nTime*nTime
where the “n” indicates the units have been normalized.
The equation has a single coefficient for time and load and time squared which applies to the entire data set.  When Unit = 0 that part of the equation goes to 0 and when unit = 1 then 3.6 is subtracted from the intercept.

0
#185947

Lee
Participant

Tnaks for the reply.   In the stepwise regression (or regular) MiniTab is not producing a warning about the squared time, but it is nice to know about how to sidestep that issue via normalization.
Now, is it ossible to have the coefficient of the Load to be different, .e., what I am getting is

0
#185948

Lee
Participant

Let me try again, sans fat fingers ;)
Thanks for the reply.   In the stepwise regression (or regular) MiniTab is not producing a warning about the squared time, but it is nice to know about how to sidestep that issue via normalization.
Now, is it possible to have the coefficient of the Load to be different, i.e., what I am getting is
What I want is
In other words, I want to see the differing slope for the Loads for the units rather than having them lumped together.   I do want the coefficient for time to be the same though.

Eugene

0
#185950

Lee
Participant

Found the technique of what I wanted.  Each unit has a different variable name for the load, and each unit for which the load is not applicable has the load set to zero.  That forces the coefficient on Time to be the same in all units and each unit then comes up with a different coefficient on Load.
Thanks for the new perspective that started breaking up my mindset.

0
Viewing 5 posts - 1 through 5 (of 5 total)

The forum ‘General’ is closed to new topics and replies.