refactor(bin_residuals): updated docstring and variable naming