Hi,
Could the below calculation be implemented in cognos to calculate the 25th Percentile.
for example:
Array[1] = 1
Array[2] = 2
Array[3] = 3
Array[4] = 4
To calculate 25th percentile
p = 25
n = 4 (# of elements in array)
x = 1 + ((p/100) * (n-1))
x = 1 + (.25 * 3) = 1.75
k = 1 (integer part of x)
d = .75 (fractional part of x)
If d = 0 then
25th percentile = Array[k]
Else
L = d * ( Array[k+1] – Array[k] ) = .75 * (2 – 1) = .75
25th percentile = Array[k] + L = 1 + .75 = 1.75
End-If;
Currently we have count of records. Could someone let me know whether it is possible to create arrays in cognos or is it possible to implement the above calculation using count of records
Thanks in advance,