A gardener has measured one flower. They want to know the species, how sure the model is, and how good the model is in general.
Task: write classify_flower(flower, k, seed). flower is a list of 4 numbers in the iris column order.
X and y with load_iris(return_X_y=True, as_frame=True).train_test_split(X, y, test_size=0.2, random_state=seed, stratify=y).KNeighborsClassifier(n_neighbors=k) on the training rows."score": the test score, rounded to 3 decimal places."species": the predicted species name for flower, as a string."confidence": the probability of that predicted species, rounded to 2 decimal places.Pass the flower as a one-row DataFrame with the iris column names.