Improved the optimized data retrieval to load the raw data, when there are less points than requested.
Updated the junit tests.