anchor.diff:  
   float_round(X) -> float(trunc(1000.0 * X)) / 1000.0.
   
  +deltas(undefined)  -> undefined;
  +deltas([])         -> [];
  +deltas([X | Rest]) -> deltas(Rest, X, []).
  +
  +deltas([], _, Acc) -> lists:reverse(Acc);
  +deltas([X | Rest], Prev, Acc) ->
  +    deltas(Rest, X, [erlang:max(X - Prev, 0) | Acc]).
  +
   -ifdef(EUNIT).
   
   test() ->
  
positive.code:                                proplists:get_value("get_hits", Samples5),
                                 proplists:get_value("cmd_get", Samples5))} |
                  Samples5],
      {ok, SamplesInterval, LastSampleTStamp, Samples6}.
  
  build_bucket_stats_ops_response(PoolId, BucketId, Params) ->
      {ok, SamplesInterval, LastSampleTStamp, Samples2} =
  
negative.code:     ?assertEqual(1.08, float_round(1.0800099)),
      ok.
  
  deltas_test() ->
      ?assertEqual([], deltas([])),
      ?assertEqual([], deltas([10])),
      ?assertEqual([0], deltas([10, 10])),
      ?assertEqual([0, 0], deltas([10, 10, 10])),
      ?assertEqual([0, 0, 0],
                   deltas([10, 10, 10, 10])),
      ?assertEqual([0, 1, 1],
                   deltas([10, 10, 11, 12])),
      ?assertEqual([0, 1, 1, 0],
                   deltas([10, 10, 11, 12, 12])),
      ok.
  
  -endif.
  
  