code: def feature_scaling(x, xmin, xmax, a=0, b=1):
      '''Generalized feature scaling (useful for variable error correction rate calculation)'''
      return a + float(x - xmin) * (b - a) / (xmax - xminf feature_scaling(x, xmin, xmax, a=0, b=1):
      '''Generalized feature scaling (useful for variable error correction rate calculation)'''
      return a + float(x - xmin) * (b - a) / (xmax - xmin)
docs: Generalized feature scaling (useful for variable error correction rate calculation)