How can I apply my model with optimize parameters on a test set?

Samira_123Samira_123 Member Posts: 9 Contributor I
Hello,

I have a question  regarding my classification assignment. I have to predict whether or not donors will donate (class 0 and class 1).

I built a model thanks to the 'optimize parameters' (as it was advised here) and I used the random forest. I got a relevant kappa, a good coefficient matrix and a costs matrix.

The performance of the model is satisfying but I have an issue.
I want to 'Apply Model' on a test set (from read csv) with the model I built with optimize parameters. However, when I try to apply the model to get the predictions of the this test set, there is an issue with rapid miner. 


I need to apply the model on this test set to get the class predictions of the donors but unfortunately I can't. 

I tried to find information online but didn't find anything relevant. The way I proceed is perhaps not correct.

Once I get the class predictions from this test set, I have to use the write csv.

Thank you,

Wish you all a good weekend!  

Best Answer

Answers

  • lionelderkrikorlionelderkrikor Moderator, RapidMiner Certified Analyst, Member Posts: 1,193 Unicorn
    Hi @Samira_123,

    You can use, in your training process , the Store operator to store your trained model in the RapidMiner repository  : 


    Then open a new process and retrieve the model from the RapidMiner repository and use it to score your test set via Apply Model operator :

     


    In attached files, the 2 processes using the Titanic datasets (training and testing).

    If you still encounter an error after performing the proposed solution , please describe your issue, share your process and your data in order we can reproduce, understand and fix your issue.

    Regards,

    Lionel
    Jasmine_
  • Samira_123Samira_123 Member Posts: 9 Contributor I
    Hi @lionelderkrikor,

    Thank you for your answer :smile:

    I did these steps. Here you can find the screenshots and the datasets of my model and my database. I had to join the first 3 tables to build my model, then I needed to use donors to predict as my test set (there is only one column in this dataset 'potentional donors'). 

    I did this initally but there is still an issue


  • Samira_123Samira_123 Member Posts: 9 Contributor I
    @lionelderkrikor

    As there is only one column in donors to predict, I should have joined the 4 tables in the beginning instead of joining only 3 of them. 

    I was just afraid to biaised my model by using it in the beginning but I use split data in the optimizer process. 

    Thank you for your answer :smile:
    lionelderkrikor
Sign In or Register to comment.