..
R source code for article: https://win-vector.com/2017/09/28/partial-pooling-for-lower-variance-variable-encoding/