C# Class BigML.Model.LocalModel

Datei anzeigen Open project: bigmlcom/bigml-csharp

Public Methods

Method Description
getFieldById ( string fieldId ) : DataSet.Field
getFieldByName ( string fieldName ) : DataSet.Field
predict ( dynamic>.Dictionary inputData, bool byName = true, int missing_strategy ) : Node

Generates a prediction based on this Model

prepareInputData ( dynamic>.Dictionary inputData, bool byName = true ) : dynamic>.Dictionary

Clean input data introduced for a prediction removing fields without valid value and populates the result's Dictionary by fieldID

Private Methods

Method Description
LocalModel ( JsonValue jsonObject, DataSet.Field>.Dictionary fields ) : System
countWords ( string inData, string predicateValue ) : int
getFieldInfo ( string fieldId ) : DataSet.Field
getFieldTermAnalysis ( DataSet currentField ) : string>.Dictionary
predictNode ( Node currentNode, dynamic>.Dictionary inputData ) : Node
termMatches ( string text, string fieldLabel, string term ) : int

Method Details

getFieldById() public method

public getFieldById ( string fieldId ) : DataSet.Field
fieldId string
return DataSet.Field

getFieldByName() public method

public getFieldByName ( string fieldName ) : DataSet.Field
fieldName string
return DataSet.Field

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

prepareInputData() public method

Clean input data introduced for a prediction removing fields without valid value and populates the result's Dictionary by fieldID
public prepareInputData ( dynamic>.Dictionary inputData, bool byName = true ) : dynamic>.Dictionary
inputData dynamic>.Dictionary Original input data
byName bool
return dynamic>.Dictionary