news News
software Software
+ emacs configuration
+ latex templates
+ libdatamining
+ otp-wrapper
+ libneuralnet
+ libsocket
+ cross compilation
+ usefull C++ libs
people People
about About
cvs Documentation
 
Login
Password
Use SSL
Designed by Initd.org

Valid XHTML 1.1

 
Generic C++ Datamining library

Description

Happycoders datamining C++ library implements public datamining algorithms. It provides an implementation of ID3, CART and C4.5 datamining algorithms. Theses algorithms generate decision trees that can be used to classify data. This library is released under the term of the GNU LGPL licence.

Features

  • provides libdata : generic library to manipulate generic data (csv, database via ODBC)
  • implement ID3 algorithm
  • implement CART algorithm
  • implement C4.5 algorithm
  • implement CHAID algorithm (not yet released)
  • all algorithms have the same API (changing the algorithm only takes a few seconds)

Installation

  • get last release : libdatamining-0.2.tar.gz
  • get the debian packages : happycoders-libdatamining, happycoders-libdatamining-dev, happycoders-libdata and happycoders-libdata-dev add this line to /etc/apt/sources.list :
        deb http://debian.speedblue.org ./
    

Doxygen Documentation

Doxygen documentation is available here .

Example


int main(int argc, char **argv)
{
  Data::CsvLoader   loader;

  if (argc < 4)
    {
      std::cerr << "Usage : " << argv[0]
                << " filename.csv separator_character "
                << "col_classification_result_name"
                << std::endl;
      exit (1);
    }
  try
    {
      std::string filename(argv[1]);
      std::vector<unsigned int> learning;
      std::string col_name(argv[3]);

      std::vector<Data::Column*>    cols;
      cols = loader.read_file(filename, argv[2][0]);
      for (unsigned int i = 0; i < cols[0]->get_size() / 2; i++)
        learning.push_back(i);
      Algo::CART        cart(cols, learning, col_name);
      cart.construct_tree();
      std::cout << cart.get_tree() << std::endl;
    }
  catch (Exception::Exception e)
    {
      std::cerr << e;
      exit (1);
    }
  return 0;
}

 
(c) 2002, 2003, 2004, 2005, 2006 Happycoders