Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


Explain about confusion matrix in r?



Explain about confusion matrix in r?..

Answer / Suman Pal

"A confusion matrix is a table used to describe the performance of a classification model. It summarizes the number of true positives (TP), false positives (FP), true negatives (TN), and false negatives (FN) for a binary classification problem.nnIn R, you can use the caret package to calculate a confusion matrix:n```Rnlibrary(caret)nn# Train a classification modelnmodel <- train(y ~ ., data = training_data, method = 'naive_bayes')nn# Predict on new datanpredictions <- predict(model, newdata = testing_data)nn# Calculate the confusion matrixnconfusionMatrix(predict(model, newdata = testing_data), testing_data$y)n```

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More R Programming Interview Questions

What are vector functions?

1 Answers  


What is the main difference between an Array and a matrix?

1 Answers  


Which function is used to write files?

1 Answers  


Explain DBSCAN algorithm in R?

1 Answers  


How many types of data types are provided by R?

1 Answers  


What is factor variable in r language?

1 Answers  


What are various steps involved in analytics project in r?

1 Answers  


What is Descriptive analysis in R?

1 Answers  


What is logistic regression?

1 Answers  


What is R?

1 Answers  


Which function is used to create a histogram visualisation in r programming language?

1 Answers  


Explain different types of objects present in R?

1 Answers  


Categories