private void adaptHistories(int numberOfDeletions){
		for (int i = 0; i < numberOfDeletions; i++){
			SortedSet<Integer> keys = new TreeSet<>(this.predictionHistories.keySet());
			this.predictionHistories.remove(keys.first());
			keys = new TreeSet<>(this.predictionHistories.keySet());
			for (Integer key : keys){
				List<Integer> predHistory = this.predictionHistories.remove(key);
				this.predictionHistories.put(key-keys.first(), predHistory);
			}
		}
	}
private void adaptHistories ( int numberOfDeletions ) { for ( int i = 0 ; i < numberOfDeletions ; i ++ ) { SortedSet < Integer > keys = new TreeSet < > ( this . predictionHistories . keySet ( ) ) ; this . predictionHistories . remove ( keys . first ( ) ) ; keys = new TreeSet < > ( this . predictionHistories . keySet ( ) ) ; for ( Integer key : keys ) { List < Integer > predHistory = this . predictionHistories . remove ( key ) ; this . predictionHistories . put ( key - keys . first ( ) , predHistory ) ; } } }
Removes predictions of the largest window size and shifts the remaining ones accordingly.