Someday, Neha, you will learn to post a reproducible example using plain text. I hope.
Try using the reprex package. On April 15, 2020 2:32:03 PM PDT, Neha gupta <neha.bologn...@gmail.com> wrote: >What is the problem is the code.. > >d=readARFF("CM1.arff") > >index <- createDataPartition(d$Defective, p = .70,list = FALSE) >tr <- d[index, ] >ts <- d[-index, ] >index_2 <- createFolds(tr$Defective, returnTrain = TRUE, list = TRUE) > >ctrl <- trainControl(method = "boot", number=100, index = index_2, >search="random", classProbs = TRUE, > summaryFunction=twoClassSummary,savePredictions = T) > > >net <- train(Defective ~ ., data = tr, > method = "nnet", > metric = "ROC", > preProc = c("center", "scale", "nzv" ), > trControl = ctrl, na.action=na.exclude) >getTrainPerf(net) > > >I am getting the error as below: > >Something is wrong; all the ROC metric values are missing: > ROC Sens Spec > Min. : NA Min. : NA Min. : NA > 1st Qu.: NA 1st Qu.: NA 1st Qu.: NA > Median : NA Median : NA Median : NA > Mean :NaN Mean :NaN Mean :NaN > 3rd Qu.: NA 3rd Qu.: NA 3rd Qu.: NA > Max. : NA Max. : NA Max. : NA > NA's :3 NA's :3 NA's :3 > > [[alternative HTML version deleted]] > >______________________________________________ >R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see >https://stat.ethz.ch/mailman/listinfo/r-help >PLEASE do read the posting guide >http://www.R-project.org/posting-guide.html >and provide commented, minimal, self-contained, reproducible code. -- Sent from my phone. Please excuse my brevity. ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.