1
$\begingroup$

I have trained a conditional inference decision tree in R using library party with function ctree and saved the model in an .Rda file.

I need to migrate this model from R to Java so that I can utilise the tree to make predictions in a Java environment. Can someone please point me in the right direction on how I can do this?

$\endgroup$

1 Answer 1

2
$\begingroup$

You could convert your decision tree model to the PMML format. In Java you could use JPMML to parse/read the model and predict.

$\endgroup$
1
  • $\begingroup$ At present the R ppml function does not support party::ctree conversion to PPML format, but this wrapper github.com/jpmml/r2pmml does. $\endgroup$
    – Javide
    Jan 18, 2019 at 0:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.