Print Friendly, PDF & Email

◷ Reading Time: 2 minutes


This extension enables Predictive Analytics capability to FlexRule platform.


Trains and builds a predictive model using data.

 train (list, algorithm, class, options)
  • algorithm:
    • c45: Decision Tree
    • nb: Naive Bayes
  • class: attributes name that is the class name (i.e. attribute or field of data that going ot be the result of prediction)
  • options: Algorithm options if it is available
  • Return: analytic’s trainedModel


Uses a trained model to predict result for a data record.

 predict (trainedModel, data, options)
  • trainedModel: the train function result.
  • data: Situan that requires the prediction. (i.e. a JSON with fields of value)
  • options: Algorithm options if it is available


Extracts rules for Decision Tree.

 extractRules (trainedModel, type)
  • type: if, elseIf
  • Retrun: list of rules that are bases of the trained model


The following examples are available by default when you open FlexRule Designer.

Updated on July 9, 2019

Was this article helpful?

Related Articles