Added method to calculate percentiles to ProbabilityMassFunction