switch from Double to BigDecimal on the sampling state and propagate all the changes. It closes issue #28