added feature for variable binning