Options

ExampleSet as Operator in a process (JAVA)

sWnsWn Member Posts: 5 Contributor II
edited November 2018 in Help
Hi,

I'm trying to implement a DecisionTreeLearner and created an ExampleSet like explained in [1].

Now I'm stuck with the integration of this ExampleSet in a process with the DecisionTreeLearner. What I did was:

Process process = new Process();
DecisionTreeLearner dtl = OperatorService.createOperator(DecisionTreeLearner.class);
process.getRootOperator().getSubprocess(0).addOperator(dtl);
process.run();
How can I add my ExampleSet to the process (maybe as an operator) and connect the ports like
myInputDataExampleSet.getOutputPorts().getPortByName("nameOfOutputPort").connectTo(dtl.getInputPorts().getPortByName("training set"));
I can only find examples where the data is coming from an input file and I can't find an operator to which I can simply add my ExampleSet.

Thanks and Sincerely
sWn

Sources:
[1] http://rapid-i.com/wiki/index.php?title=Integrating_RapidMiner_into_your_application#Transform_data_for_RapidMiner
Tagged:

Answers

  • Options
    Marco_BoeckMarco_Boeck Administrator, Moderator, Employee, Member, University Professor Posts: 1,995 RM Engineering
    Hi,

    I would suggest you use the recommended way of executing a RapidMiner process you previously built via the RapidMiner GUI, instead of trying to create one from scratch.
    See here and read my two replies and then read this as well. That should tell you all you need to know ;)

    Regards,
    Marco
  • Options
    sWnsWn Member Posts: 5 Contributor II
    Hi,

    thanks for your reply! That really seems to be a much easier way to solve my problem.

    Sincerely
    sWn
Sign In or Register to comment.