Add quantize() method