Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BaggedModel ¶
type BaggedModel struct { base.BaseClassifier Models []base.Classifier RandomFeatures int // contains filtered or unexported fields }
BaggedModel trains base.Classifiers on subsets of the original Instances and combine the results through voting
func (*BaggedModel) AddModel ¶
func (b *BaggedModel) AddModel(m base.Classifier)
AddModel adds a base.Classifier to the current model
func (*BaggedModel) Fit ¶
func (b *BaggedModel) Fit(from *base.Instances)
Train generates and trains each model on a randomised subset of Instances.
func (*BaggedModel) Predict ¶
func (b *BaggedModel) Predict(from *base.Instances) *base.Instances
Predict gathers predictions from all the classifiers and outputs the most common (majority) class
IMPORTANT: in the event of a tie, the first class which achieved the tie value is output.
func (*BaggedModel) String ¶
func (b *BaggedModel) String() string
String returns a human-readable representation of the BaggedModel and everything it contains
Click to show internal directories.
Click to hide internal directories.