kotlin-statistics v1.1.0 Release Notes
Release Date: 2018-04-07 // about 6 years ago-
๐ This release has a new
NaiveBayesClassifier
, as well as some generic projection fixes for theBin
andBinModel
types.๐ See README for examples.
val nbc = bankTransactions.toNaiveBayesClassifier( featuresSelector = { it.memo.splitWords().toSet() }, categorySelector = { it.category } ) //TESTval input = BankTransaction(date = LocalDate.of(2018,3,31), amount = 13.99, memo = "NETFLIX VIDEO ON DEMAND #21" ) val result = nbc.predict(input.memo.splitWords().toSet()) println(result) // prints "ENTERTAINMENT"