fixed select-model so that now returns model is model = 0 and n.model = 1