Description
Calculates the value for a specified percentile (P) in a Number or Currency field.
Overloads
PthPercentile (P, fld, condFld)
PthPercentile (P, fld, condFld, cond)
Arguments
P is any integer between 0 and 100.
fld is any Number or Currency field that can be evaluated by the function.
condFld is a field used to group the values in fld by.
cond is a String indicating the type of grouping for condFld. You only specify this argument when condFld is a Date, Time, DateTime or Boolean field.
Returns
Number or Currency value
Action
Calculates the value for a specified percentile (P) in a Number or Currency field.
Examples
PthPercentile(20, {Customer.LAST YEAR'S SALES})
Returns $2302 as the value at the 20th percentile (if 20% of {Customer.LAST YEAR'S SALES are less than $2302
PthPercentile(P, {Customer.LAST YEAR'S SALES}, {Customer.REGION})
Groups the Last Year's Sales field by region and returns the value at percentile P in the Last Year's Sales field per region.
PthPercentile(P,{orders.ORDER AMOUNT}, {Customer.REGION}, "monthly")
Groups values in the Amount field by region, then returns the value at percentile P in the Amount field for each region, per month.
Comments
P = 50 (the 50
th Percentile) is the same value returned by the
Median function (the median value).
Using this function in a formula forces the formula to be evaluated at print time.
For more information on evaluation time considerations, see
Evaluation Time.