Better handling of graph averaging for different thresholds Refactored predict to doAveraging, not returning anymore a Grap but rather modifying the reference