creating setRangeData method to get median data from cache (not tested yet)