Project

idhja22

0.0
No commit activity in last 3 years
No release in over 3 years
Classifiers
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

>= 0
~> 2.10
>= 0

Runtime

 Project Readme

Idhja22

Build Status

Mostly my attempt at writing a gem.

Used for training a binary classifying tree (target values should be Y or N). Leaf nodes are a probability of Y rather than a Y or N.

Installation

Add this line to your application's Gemfile:

gem 'idhja22'

And then execute:

$ bundle

Or install it yourself as:

$ gem install idhja22

Usage

Simplest usage is to have a CSV of training data. The final column is treated as the target category value of each entry, the other columns are attributes for each datum. The first row is used as for attribute and target category labels.

> tree = Idhja22::Tree.train_from_csv('/path/to/data.csv')

To print out the rules produced by the tree:

> puts tree.get_rules

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request