added minimum and maximum argument feature