add variance computation