updated and fixed metrics, added documentation