Re:An Introduction to Hierarchical Modeling
by antipaul on Thursday March 04, 2021 @01:41PM
(#26346340)
What if you simply add department and department*salary interaction terms to a standard regression model?
[ Parent
| on HN ]
Re:An Introduction to Hierarchical Modeling
by aseerdbnarng on Thursday March 04, 2021 @01:55PM
(#26346538)
You'll run out of data pretty quickly.
https://statmodeling.stat.columbia.edu/2018/03/15/need-16-ti...
Re:An Introduction to Hierarchical Modeling
by alisonkisk on Friday March 05, 2021 @08:12AM
(#26356449)
Hierarchial model has the same problem, since it splits up the data into categories.
Re:An Introduction to Hierarchical Modeling
by wodenokoto on Thursday March 04, 2021 @01:51PM
(#26346490)
Then for any given data point, salary for all other departments will be zero (dep1salery = dep2salary = ... = 0) so data for each department will become separate and you will in effect have i number of different models, although they all share the same bias term / intersect.
Re:An Introduction to Hierarchical Modeling
by plouffy on Thursday March 04, 2021 @02:03PM
(#26346637)
You could argue that a hierarchical model is already multiple models. If each department has a dummy variable then they wouldn't share the same intersect. The only difference is how you interpret that intercept. The department intercept would now not be the salary of an individual with 0 experience, but the difference between the salary of an individual with 0 experience in a department compared to the all other employees with 0 experience.
Re:An Introduction to Hierarchical Modeling
by wodenokoto on Friday March 05, 2021 @08:49AM
(#26356813)
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.
Re:An Introduction to Hierarchical Modeling
by alisonkisk on Friday March 05, 2021 @08:14AM
(#26356473)
I think it gives you the same answer without having the intuitive picture of your kernel that people like for toy problems.