brain

package
v1.2.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 26, 2019 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var VERSION = "v0.0.1"

Functions

This section is empty.

Types

type BayesBrain

type BayesBrain struct {
	FeaturesFrequency               map[string]int
	CategoriesFrequency             map[string]int
	FeaturesFrequencyInEachCategory map[string]map[string]int
}

func NewBayesBrain

func NewBayesBrain() *BayesBrain

func (*BayesBrain) Learn

func (brain *BayesBrain) Learn(category string, features ...string)

func (*BayesBrain) Load

func (brain *BayesBrain) Load(filename string) error

func (*BayesBrain) Save

func (brain *BayesBrain) Save(filename string) error

func (*BayesBrain) Show

func (brain *BayesBrain) Show()

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL