Changed latency calculation and output