Forums before death by AOL, social media and spammers... "We can't have nice things"
|    comp.ai    |    Awaiting the gospel from Sarah Connor    |    1,954 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 1,805 of 1,954    |
|    Tim Frink to All    |
|    Parsing decision trees    |
|    20 Sep 08 03:17:53    |
   
   From: plfriko@yahoo.de   
      
   Hi,   
      
   I'm looking for a way to parse decision trees that very   
   generated with a machine learning tool into equivalent   
   C++ code.   
      
   Let's say I've learning data stored in a CSV file that looks   
   like this:   
      
   a b c label   
   1 3 5 0   
   0 5 2 1   
   ...   
      
   The decision tree represents a classification that is used to steer   
   a particular routine within a C++ program. The column notations (a,b,c)   
   are real variables within the routine. 'a' is a boolean variable, while   
   'b' and 'c' are numeric (integer) variables. There are some tools which   
   can import this CSV file and automatically generate a decision tree. These   
   trees can be translated by hand into equivalent if-then-else C++   
   statements. However, this is very tedious for larger trees.   
   Moreover, I would like to use the leave-one-one cross-validation for which   
   I have to generate as many decision trees as many examples I have. This   
   cannot be done manually in an acceptable amount of time.   
      
   Do you know a tool that allows a generation of decision trees that can   
   be automatically translated int into C++ code like   
      
   if( a < 10 ) {   
    if( b > 20 )   
    return true;   
    else if( c < 100 )   
    return false;   
   }   
      
   Thank you for your help.   
      
   Regards,   
   Tim   
      
   [ comp.ai is moderated ... your article may take a while to appear. ]   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   
|
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca