BigML.Model.LocalModel.predict C# (CSharp) Method

predict() public method

Generates a prediction based on this Model
public predict ( dynamic>.Dictionary inputData, bool byName = true, int missing_strategy ) : Node
inputData dynamic>.Dictionary Map with the ID or name of each field and its value
byName bool Flag for the inputData key: /// * true if fieldName is the key, /// * false if the key is the field ID
missing_strategy int Which strategy should use the prediction
return Node
            public Node predict(Dictionary<string, dynamic> inputData, bool byName=true, int missing_strategy=0)
            {
                if (byName)
                {
                    inputData = prepareInputData(inputData, byName);
                }

                // if Model was not processed before => creates root Node
                if (rootNode == null) {
                    rootNode = new Node(this._jsonObject["root"]);
                }

                return predictNode(rootNode, inputData);
            }