id3-tree-builder

0.0.1 • Public • Published

ID3 Tree Builder

This is a simple library that allows you to quickly generate decision trees based on examples. The algorithm used is ID3.

Installation

npm install --save id3-tree-builder

Usage

See the example script for how to build a tree from examples. The example data is taken from http://willkurt.github.io/ID3-Decision-Tree/.

The basic usage works like this:

const Id3TreeBuilder = require('id3-tree-builder');
const examples = [{"Attribute": "Value 1", "class": "Class 1"}]; // your array of examples
const builder = new Id3TreeBuilder();
const tree = builder.build(examples);

All of your examples need to have the same properties set. Also, their class name needs to be set in the class property.

Package Sidebar

Install

npm i id3-tree-builder

Weekly Downloads

1

Version

0.0.1

License

BSD-3-Clause

Unpacked Size

9.83 kB

Total Files

6

Last publish

Collaborators

  • fchristl