# Coefficient estimate of multiple interaction terms in regression model

I am trying to estimate coefficient of a regression model with two interaction terms. I would appreciate any help. I will try to recreate my model then ask the question.

Crew = A, B
Shift = Day, Night

Y = Crew + Shift + Health + Crew * Shift + Crew * Health

Sample coefficients from model:

Coefficients:

Intercept = 1
CrewB = 2
ShiftNight = 3
CrewB:ShiftNight = 4

Here, CrewA, ShiftDay and HealthGood is baseline.


Now, In case of CrewB working during ShiftDay, the coefficient will be = 1 + 2
And When CrewB working on HealthGood, the coefficient will be = 1 + 2

This does not make sense to me. I am making mistake somewhere, I would appreciate if someone explain how to interpret this kind of multiple interaction.

Thank you very much.

Note that each individual will be characterized by the 3 variables.

So, what you have is
(CrewB, ShiftDay, HealthGood), that gives the result
1 + 2 + 0 + 0 + 0 + 0.

Other examples could be
(CrewA, ShiftNight, HealthGood), with the result
1 + 0 + 3 + 0 + 0 + 0;

and
(CrewB, ShiftDay, HealthBad), with the result
1 + 2 + 0 + 10 + 0 + 5.

Edit:

In response to your comment, I'll provide two more examples:
(CrewB, ShiftNight, HealthGood), results in
1 + 2 + 3 + 0 + 4 + 0;

and
(CrewB, ShiftNight, HealthBad), results in
1 + 2 + 3 + 10 + 4 + 5.

• Thank you very much. So, to estimate the interaction coefficient for (Crew, Shift), I shouldn’t add a third variable to the model. – moeen Sep 7 at 2:00
• You're welcome.You already have 3 variables and you don't need more variables to have those interaction coefficients (crew * shiftis already present in your model). And you can consider two other interaction terms: Shift * Health and Crew * Shift * Health. – Ertxiem Sep 7 at 10:57

To describe effects of variables engaged in one or more interactions, you can use the technique described below.

List Equation of Fitted Model

Based on the information you provided, the expected/average value of Y given the predictors included in the model can be expressed like this:

Expected value of Y = 1 + 2*CrewB + 3*ShiftNight + 10*HealthBad + 4*CrewB:ShiftNight + 5*CrewB:HealthBad


where:

• CrewB = 1 for crew B and 0 for crew A;
• ShiftNight = 1 for night shift and 0 for day shift;
• HealthBad = 1 for bad health and 0 for good health.

Quantify Effect of Crew

What happens if you want to determine the effect of crew from your fitted model listed above? Simply re-arrange your model by grouping together all the terms in the model which include the dummy variable CrewB:

Expected value of Y = 1 + (2 + 4*ShiftNight + 5*HealthBad)*CrewB + 3*ShiftNight + 10*HealthBad


Thus, the effect of crew on subjects sharing the same type of shift and the same type of health is captured by the coefficient (2 + 4*ShiftNight + 5*HealthBad). This effect depends on both the type of shift and on the type of health. For example:

• The effect is equal to 2 for subjects working the day shift (for whom ShiftNight = 0) and having good health (for whom HealthBad = 0) - in other words, the expected value of Y is higher by 2 units for subjects working the day shift and having good health who belong to crew B compared to those sharing the same characteristics but who belong to crew A;
• The effect is equal to 2 + 4 + 5 = 11 for subjects working the night shift (for whom ShiftNight = 1) and having bad health (for whom HealthBad = 1) - in other words, the expected value of Y is higher by 11 units for subjects working the night shift and having bad health who belong to crew B compared to those sharing the same characteristics but who belong to crew A.

You can consider all possible combinations of shift and health status in order to describe the effect of crew on the expected value of Y; in the above, I only considered 2 of the 4 possible combinations of values of shift and health status.

You can and should also construct confidence intervals to go with the reported point estimates 2, 11, etc.

Quantify Effect of Shift

What if you are interested in quantifying the effect of shift on the expected value of Y? Then you need to re-express your model like this:

Expected value of Y = 1 + 2*CrewB + (3 + 4*CrewB) * ShiftNight + 10*HealthBad + 5*CrewB:HealthBad


From this re-expression, you can see that, for subjects with the same health status, the effect of shift depends on crew. Specifically:

• The estimated effect of shift is 3 for subjects in crew A sharing the same health status (since CrewB = 0 for them) - these subjects have an expected value of Y that is higher by 3 units under the night shift than under the day shift; Specifically:

• The estimated effect of shift is 3 + 4 = 7 for subjects in crew B sharing the same health status (since CrewB = 1 for them) - these subjects have an expected value of Y that is higher by 7 units under the night shift than under the day shift.

Again, you can construct confidence intervals to go with the reported point estimates 3 and 7 of night shift.

Quantify Effect of Health Status

Finally, if you wanted to report the effect of health status, you would have to re-express your fitted model as:

Expected value of Y = 1 + 2*CrewB + 3*ShiftNight + (10 + 5*CrewB)*HealthBad + 4*CrewB:ShiftNight


Clearly, the effect of health status among subjects working the same type of shift depends on crew. This effect is estimated to be 10 for subjects working the same type of shift in crew A and it is estimated to be 15 for subjects working the same type of shift in crew B.

To construct the suggested confidence intervals, you would need to construct and estimate appropriate linear combinations of the (true) model coefficients.