When I run my code, I get the following error and suddenly the execution of the script stops. Where in my data is the problem? Something is wrong; all the MAE metric values are missing: RMSE Rsquared MAE 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 :8 NA's :8 NA's :8 Error: Stopping [[alternative HTML version deleted]]
Patrick (Malone Quantitative)
2019-Dec-20 23:06 UTC
[R] script execution stops and give the error
Per the posting guide, post your script and use plain text. There's no way anyone can possibly help with only this information. On Fri, Dec 20, 2019 at 5:33 PM Neha gupta <neha.bologna90 at gmail.com> wrote:> > When I run my code, I get the following error and suddenly the execution > of the script stops. Where in my data is the problem? > > Something is wrong; all the MAE metric values are missing: > RMSE Rsquared MAE > 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 :8 NA's :8 NA's :8 > Error: Stopping > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help at 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.
The code is described below: I need to find the RMSE and MAE ///read data which have data types of integer and number. data=read.csv("fault.csv") inTraining <- createDataPartition(data$bug , p = .75,list = FALSE) training <- data [inTraining, ] testings <- data [-inTraining, ] ctrol = trainControl(method = "repeatedcv", number=5) myTrain <- train(bug ~ ., data = training, method = "rf", tuneLength = 15, metric = "MAE", preProc = c("center", "scale", "zv"), trControl = ctrol) On Fri, Dec 20, 2019 at 11:31 PM Neha gupta <neha.bologna90 at gmail.com> wrote:> When I run my code, I get the following error and suddenly the execution > of the script stops. Where in my data is the problem? > > Something is wrong; all the MAE metric values are missing: > RMSE Rsquared MAE > 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 :8 NA's :8 NA's :8 > Error: Stopping >[[alternative HTML version deleted]]
A) Plain text is a setting that you must choose in many modern email clients. Failing to do so tends to cause us to see something more or less different than what you intended us to see. B) Repeating your incomplete example is a more significant issue in this case. If you supply a reproducible example [1][2][3] we can see problems that you don't know exist... so giving us only what you think we need to see makes it that much less likely that you will even get an answer because you are not showing us the relevant information. [1] http://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example [2] http://adv-r.had.co.nz/Reproducibility.html [3] https://cran.r-project.org/web/packages/reprex/index.html (read the vignette) On December 20, 2019 3:23:14 PM PST, Neha gupta <neha.bologna90 at gmail.com> wrote:>The code is described below: I need to find the RMSE and MAE > >///read data which have data types of integer and number. >data=read.csv("fault.csv") > >inTraining <- createDataPartition(data$bug , p = .75,list = FALSE) >training <- data [inTraining, ] >testings <- data [-inTraining, ] >ctrol = trainControl(method = "repeatedcv", number=5) >myTrain <- train(bug ~ ., data = training, > method = "rf", > tuneLength = 15, > metric = "MAE", > preProc = c("center", "scale", "zv"), > trControl = ctrol) > >On Fri, Dec 20, 2019 at 11:31 PM Neha gupta <neha.bologna90 at gmail.com> >wrote: > >> When I run my code, I get the following error and suddenly the >execution >> of the script stops. Where in my data is the problem? >> >> Something is wrong; all the MAE metric values are missing: >> RMSE Rsquared MAE >> 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 :8 NA's :8 NA's :8 >> Error: Stopping >> > > [[alternative HTML version deleted]] > >______________________________________________ >R-help at 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.
This is the whole code I provided except the libraries such as library(caret) library(randomForest) data=read.csv("fault.csv") inTraining <- createDataPartition(data$bug , p = .75,list = FALSE) training <- data [inTraining, ] testings <- data [-inTraining, ] ctrol = trainControl(method = "repeatedcv", number=5) myTrain <- train(bug ~ ., data = training, method = "rf", tuneLength = 15, metric = "MAE", preProc = c("center", "scale", "zv"), trControl = ctrol) On Sat, Dec 21, 2019 at 12:23 AM Neha gupta <neha.bologna90 at gmail.com> wrote:> > The code is described below: I need to find the RMSE and MAE > > ///read data which have data types of integer and number. > data=read.csv("fault.csv") > > inTraining <- createDataPartition(data$bug , p = .75,list = FALSE) > training <- data [inTraining, ] > testings <- data [-inTraining, ] > ctrol = trainControl(method = "repeatedcv", number=5) > myTrain <- train(bug ~ ., data = training, > method = "rf", > tuneLength = 15, > metric = "MAE", > preProc = c("center", "scale", "zv"), > trControl = ctrol) > > On Fri, Dec 20, 2019 at 11:31 PM Neha gupta <neha.bologna90 at gmail.com> > wrote: > >> When I run my code, I get the following error and suddenly the >> execution of the script stops. Where in my data is the problem? >> >> Something is wrong; all the MAE metric values are missing: >> RMSE Rsquared MAE >> 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 :8 NA's :8 NA's :8 >> Error: Stopping >> >[[alternative HTML version deleted]]