# igrigorik/decisiontree

ID3-based implementation of the ML Decision Tree algorithm

Repository: https://github.com/igrigorik/decisiontree
Canonical: https://ross.abutalabs.com/products/decisiontree
Language: Ruby
License Family: other
Topics: rubyml, decision-tree, ruby, machine-learning
Last push: 2018-10-31T15:22:42+00:00

## Health v2 (maintenance only)
Score: 32/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 6400, "days_push": 2863, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases, no_license
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1490, forks 130 (observed 2026-08-28T04:04:52.400972+00:00)

## What it is
A Ruby library implementing the ID3 decision tree learning algorithm for both continuous and discrete datasets, with rule pruning (C4.5-style) and bagging support. It includes a Graphviz component for visualizing learned trees.

## Use cases
- train a decision tree classifier in ruby
- classify records with id3 algorithm
- learn from continuous and discrete datasets
- visualize a decision tree as a png with graphviz
- build a bagging ensemble of decision trees
- convert a trained tree into pruned rules

## When to choose
- you're working in Ruby and need a simple, lightweight decision tree classifier
- you want interpretable models with tree visualization via Graphviz
- your dataset is small to medium and you need ID3/C4.5-style learning

## When to avoid
- you need modern ML features like gradient boosting, deep learning, or GPU acceleration
- you need actively maintained software with recent updates and security patches
- you're not working in Ruby
- you need scalable training on very large datasets

## Facets
- artifact type: library
- maturity: maintenance
- function: machine-learning
- domain: machine-learning, data-science
- platform: ruby
- tags: decision-tree, id3, c45, bagging, graphviz-visualization, classification

## Member repositories
- igrigorik/decisiontree (main) score 32

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:52.400972+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T04:33:37.320469+00:00, confidence not recorded.
  - readme: https://github.com/igrigorik/decisiontree (fetched 2026-08-28T04:04:52.400972+00:00, sha 82b9a44d66d1)
- Data as of 2026-08-30T08:39:29.467469+00:00.
