Hacker News new | ask | show | jobs
by wodenokoto 1936 days ago
Well, two things here:

You wouldn't actually add salary as an interaction, as it is salary you are trying to predict. You'd use an interaction between experience and department to predict salary, as you correctly point out.

But usually when doing interactions, you don't apply it to the bias term, so you will get this:

    salary = b0 + b1*d1*exp + b2*d2*exp ...
And this is essentially a model for each department, but all models share the bias term, b0.

If you also interact the bias term with the dummy variable for department, you will in effect have completely independent models,

   salary = b0,1*d1 + b1*d1*exp + b0,2*d2 * b2*d2*exp ...
But I don't think that is what is normally done when applying interactions between features.

Anyway, I think we both agree, once we get our terminology aligned.