update to handle up to 3 dimensional cube so that we call scoreatprecentile with
only upto 2d data.
Merge pull request #625 from munslowa/percentile_agg

Percentile agg