Fix calculating depth for statistics in MRA.