Calculates the median value of a data flow:
Queues incoming data's into an array, sorts the array and returns the value at the position length/2.
Input Data flow.
The values must range between [0,1].
Length of the queue array.
Output sorted array (contains queued data’s).
Fill the output array with 0, according the array len max.
Clear the array and set its length to 0.
Force the data in value to be enqueued even if it hasn't changed.
Median output value.