presto-main/src/main/java/io/prestosql/operator/aggregation/RealAverageAggregation.java/RealAverageAggregation/removeInput
class RealAverageAggregation:    public static void removeInput(LongState count, DoubleState sum, long value)
    {
        count.setLong(count.getLong() - 1);
        sum.setDouble(sum.getDouble() - intBitsToFloat((int) value));
    }