> l <- lrn("classif.kknn")$train(tsk("pima"))
> l$predict(tsk("pima"))
Error in check_prediction_data.PredictionDataClassif(pdata) :
Assertion on 'as_factor(pdata$response, levels = lvls)' failed: Must have length 768, but has length 392.
Pretty sure this is because of missing values (kknn just ignores them and creates a prediction for the rows that don't contain missing values), the error message should make this clear.
Maybe this is a good time to lobby for splitting up the 'missing' property into train-missing and predict-missing or smth like that.
Pretty sure this is because of missing values (kknn just ignores them and creates a prediction for the rows that don't contain missing values), the error message should make this clear.
Maybe this is a good time to lobby for splitting up the 'missing' property into train-missing and predict-missing or smth like that.