add calculation of distance and AP for other features
changed to distance as improvement, will add parameter in the future