Skip to content

yashargorgani/decisiontreepmml

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

decisiontreepmml

A C# Library for Deploying PMML Decision Tree Model This is a library for deploying and scoring Decision Tree model PMML v4.2 implemented in IBM SPSS Modeler software. With this library you can implement a model in software, export the PMML file and deploy the model in your own application.

How to Use

In your application code, you construct a TreeModel object with path of proper PMML file:

TreeModel model = new TreeModel("E:/Drug.xml");

Then, you should create a dictionary for your data input:

Dictionary<string, object> input = new Dictionary<string, object>(); input.Add("Age", 23);
input.Add("Sex", "F");
input.Add("BP", "HIGH");
input.Add("Cholesterol", "HIGH");
input.Add("Na", 0.792535);
input.Add("K", 0.031258);

And finally with Predict function you can score your input:

model.Predict(input)
Console.WriteLine(model.Predict(input));

About

A C# Library for Deploying PMML Decision Tree Model

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages