Apply Model in RapidMiner

HeikoeWin786HeikoeWin786 Member Posts: 64 Contributor II
Dear all,

I split a dataset 75%(Training) and 25%(Testing). I pre-processed the data on training data. Then, I split the training data again (75%-25%) and perform Naive Bayes Classification. I saved the model as a result of training data. 
However, if I want to test whether my model is applicable or not, I believe I need to run my model on the 25% which I kept as the test data initially. 
Means, for 25% of initial testing data, I will perform pre-processing same as training, then, I retrieve the pre-processed test data and apply the model which I saved from the training data. 
Could you please advise if this is correct or am I doing wrong here?

thanks.
Heikoe

Best Answer

  • Telcontar120Telcontar120 Moderator, RapidMiner Certified Analyst, RapidMiner Certified Expert, Member Posts: 1,635 Unicorn
    Solution Accepted
    That would be correct, if you want to run split validation manually, which it sounds like you did.
    You could also use the Split Validation operator, which does this automatically and delivers the performance on the test portion of the data.
    But I would really recommend using Cross Validation instead, which will train and test on multiple subsets of your original data and supply the resulting validation performance automatically.
    Brian T.
    Lindon Ventures 
    Data Science Consulting from Certified RapidMiner Experts

Answers

  • sara20sara20 Member Posts: 110 Unicorn
    HeikoeWin786

    Hello

    Most of the people have this question when they start working with data with RM or other software.
    I agree with @Telcontar120, also I recommend you to read this link. :)

    https://community.rapidminer.com/discussion/55112/cross-validation-and-its-outputs-in-rm-studio#latest

    Best
    Sara
  • HeikoeWin786HeikoeWin786 Member Posts: 64 Contributor II
    @Telcontar120 Thanks for your kind input. Just one more thing, I did run the cross-validation and NBC (on the same training dataset), but I get the output result (performance matrix) as the same result for both NBC and cross-validation. Is it normal? I expected different result actually.
    Also, for the test dataset, I should retrieve the test dataset and use the "saved model" to test the data, correct?
    I mean, how to design in RM for the test dataset? (i.e. the 25% initial unlabel data).

    thanks much for your kind explanation.

    Regards,
    Heikoe
  • HeikoeWin786HeikoeWin786 Member Posts: 64 Contributor II
    @sara20
    Thanks a lot Sara, I had looked into this and tried the corss-validation :)
  • Telcontar120Telcontar120 Moderator, RapidMiner Certified Analyst, RapidMiner Certified Expert, Member Posts: 1,635 Unicorn
    Cross Validation doesn't use just 25% (or any other subset) as the test set.  It iterates over all your data and uses all of it to test. I suggest you review the help documentation or the materials on RapidMiner Academy to better understand how cross validation works if it is not clear.
    Brian T.
    Lindon Ventures 
    Data Science Consulting from Certified RapidMiner Experts
Sign In or Register to comment.