set.seed(1, sample.kind="Rounding")
fit_lda <- train(Survived ~ Fare, data = train, method = "lda")
对于上面的每一行,将显示以下消息:
警告消息:In (function (kind = NULL, normal.kind = NULL, sample.kind = NULL) : 使用了非均匀的“舍入”采样器和这个 set.seed(1, sample.kind="Rounding")