added loop so that best features are ordered