| <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
| <html xmlns="http://www.w3.org/1999/xhtml"> |
| <head> |
| <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> |
| <title>MADlib: c45.sql_in File Reference</title> |
| |
| <link href="tabs.css" rel="stylesheet" type="text/css"/> |
| <link href="doxygen.css" rel="stylesheet" type="text/css" /> |
| <link href="navtree.css" rel="stylesheet" type="text/css"/> |
| <script type="text/javascript" src="jquery.js"></script> |
| <script type="text/javascript" src="resize.js"></script> |
| <script type="text/javascript" src="navtree.js"></script> |
| <script type="text/javascript"> |
| $(document).ready(initResizable); |
| </script> |
| <link href="search/search.css" rel="stylesheet" type="text/css"/> |
| <script type="text/javascript" src="search/search.js"></script> |
| <script type="text/javascript"> |
| $(document).ready(function() { searchBox.OnSelectItem(0); }); |
| </script> |
| <script src="../mathjax/MathJax.js"> |
| MathJax.Hub.Config({ |
| extensions: ["tex2jax.js", "TeX/AMSmath.js", "TeX/AMSsymbols.js"], |
| jax: ["input/TeX","output/HTML-CSS"], |
| }); |
| </script> |
| </head> |
| <body> |
| <div id="top"><!-- do not remove this div! --> |
| |
| |
| <div id="titlearea"> |
| <table cellspacing="0" cellpadding="0"> |
| <tbody> |
| <tr style="height: 56px;"> |
| |
| |
| <td style="padding-left: 0.5em;"> |
| <div id="projectname">MADlib |
|  <span id="projectnumber">0.6</span> <span style="font-size:10pt; font-style:italic"><a href="../latest/./c45_8sql__in.html"> A newer version is available</a></span> |
| </div> |
| <div id="projectbrief">User Documentation</div> |
| </td> |
| |
| |
| |
| </tr> |
| </tbody> |
| </table> |
| </div> |
| |
| <!-- Generated by Doxygen 1.7.5.1 --> |
| <script type="text/javascript"> |
| var searchBox = new SearchBox("searchBox", "search",false,'Search'); |
| </script> |
| <script type="text/javascript" src="dynsections.js"></script> |
| <div id="navrow1" class="tabs"> |
| <ul class="tablist"> |
| <li><a href="index.html"><span>Main Page</span></a></li> |
| <li><a href="modules.html"><span>Modules</span></a></li> |
| <li class="current"><a href="files.html"><span>Files</span></a></li> |
| <li> |
| <div id="MSearchBox" class="MSearchBoxInactive"> |
| <span class="left"> |
| <img id="MSearchSelect" src="search/mag_sel.png" |
| onmouseover="return searchBox.OnSearchSelectShow()" |
| onmouseout="return searchBox.OnSearchSelectHide()" |
| alt=""/> |
| <input type="text" id="MSearchField" value="Search" accesskey="S" |
| onfocus="searchBox.OnSearchFieldFocus(true)" |
| onblur="searchBox.OnSearchFieldFocus(false)" |
| onkeyup="searchBox.OnSearchFieldChange(event)"/> |
| </span><span class="right"> |
| <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a> |
| </span> |
| </div> |
| </li> |
| </ul> |
| </div> |
| <div id="navrow2" class="tabs2"> |
| <ul class="tablist"> |
| <li><a href="files.html"><span>File List</span></a></li> |
| <li><a href="globals.html"><span>File Members</span></a></li> |
| </ul> |
| </div> |
| </div> |
| <div id="side-nav" class="ui-resizable side-nav-resizable"> |
| <div id="nav-tree"> |
| <div id="nav-tree-contents"> |
| </div> |
| </div> |
| <div id="splitbar" style="-moz-user-select:none;" |
| class="ui-resizable-handle"> |
| </div> |
| </div> |
| <script type="text/javascript"> |
| initNavTree('c45_8sql__in.html',''); |
| </script> |
| <div id="doc-content"> |
| <div class="header"> |
| <div class="summary"> |
| <a href="#func-members">Functions</a> </div> |
| <div class="headertitle"> |
| <div class="title">c45.sql_in File Reference</div> </div> |
| </div> |
| <div class="contents"> |
| |
| <p>C4.5 APIs and main controller written in PL/PGSQL. |
| <a href="#details">More...</a></p> |
| |
| <p><a href="c45_8sql__in_source.html">Go to the source code of this file.</a></p> |
| <table class="memberdecls"> |
| <tr><td colspan="2"><h2><a name="func-members"></a> |
| Functions</h2></td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">c45_train_result </td><td class="memItemRight" valign="bottom"><a class="el" href="c45_8sql__in.html#a4fbee855d22101d15d195d573189eb98">c45_train</a> (text split_criterion, text training_table_name, text result_tree_table_name, text validation_table_name, text continuous_feature_names, text feature_col_names, text id_col_name, text class_col_name, float confidence_level, text how2handle_missing_value, int max_tree_depth, float node_prune_threshold, float node_split_threshold, int verbosity)</td></tr> |
| <tr><td class="mdescLeft"> </td><td class="mdescRight">This is the long form API of training tree with all specified parameters. <a href="#a4fbee855d22101d15d195d573189eb98"></a><br/></td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">c45_train_result </td><td class="memItemRight" valign="bottom"><a class="el" href="c45_8sql__in.html#a6c039416b94686b915e2a4c1133a5d44">c45_train</a> (text split_criterion, text training_table_name, text result_tree_table_name, text validation_table_name, text continuous_feature_names, text feature_col_names, text id_col_name, text class_col_name, float confidence_level, text how2handle_missing_value)</td></tr> |
| <tr><td class="mdescLeft"> </td><td class="mdescRight">C45 train algorithm in short form. <a href="#a6c039416b94686b915e2a4c1133a5d44"></a><br/></td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">c45_train_result </td><td class="memItemRight" valign="bottom"><a class="el" href="c45_8sql__in.html#a18b30ff1a063e7cd16274bf7ab2a71dc">c45_train</a> (text split_criterion, text training_table_name, text result_tree_table_name)</td></tr> |
| <tr><td class="mdescLeft"> </td><td class="mdescRight">C45 train algorithm in short form. <a href="#a18b30ff1a063e7cd16274bf7ab2a71dc"></a><br/></td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">set< text > </td><td class="memItemRight" valign="bottom"><a class="el" href="c45_8sql__in.html#ac71787c47795b3b0b133cdbd37438242">c45_genrule</a> (text tree_table_name, int verbosity)</td></tr> |
| <tr><td class="mdescLeft"> </td><td class="mdescRight">Display the trained decision tree model with rules. <a href="#ac71787c47795b3b0b133cdbd37438242"></a><br/></td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">set< text > </td><td class="memItemRight" valign="bottom"><a class="el" href="c45_8sql__in.html#acdba07d3897356a75666aa6d5999f490">c45_genrule</a> (text tree_table_name)</td></tr> |
| <tr><td class="mdescLeft"> </td><td class="mdescRight">Display the trained decision tree model with rules. <a href="#acdba07d3897356a75666aa6d5999f490"></a><br/></td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">set< text > </td><td class="memItemRight" valign="bottom"><a class="el" href="c45_8sql__in.html#a32d2bcbc016c990991d77b6f6148306d">c45_display</a> (text tree_table, int max_depth)</td></tr> |
| <tr><td class="mdescLeft"> </td><td class="mdescRight">Display the trained decision tree model with human readable format. <a href="#a32d2bcbc016c990991d77b6f6148306d"></a><br/></td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">set< text > </td><td class="memItemRight" valign="bottom"><a class="el" href="c45_8sql__in.html#ad7f190eb8e5d53f4772fac699787c0fe">c45_display</a> (text tree_table)</td></tr> |
| <tr><td class="mdescLeft"> </td><td class="mdescRight">Display the whole trained decision tree model with human readable format. <a href="#ad7f190eb8e5d53f4772fac699787c0fe"></a><br/></td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">c45_classify_result </td><td class="memItemRight" valign="bottom"><a class="el" href="c45_8sql__in.html#afe136e52f498f2ff9e2b91e38e29d670">c45_classify</a> (text tree_table_name, text classification_table_name, text result_table_name, int verbosity)</td></tr> |
| <tr><td class="mdescLeft"> </td><td class="mdescRight">Classify dataset using trained decision tree model. The classification result will be stored in the table which is defined as: CREATE TABLE classification_result ( id INT|BIGINT, class SUPPORTED_DATA_TYPE, prob FLOAT );. <a href="#afe136e52f498f2ff9e2b91e38e29d670"></a><br/></td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">c45_classify_result </td><td class="memItemRight" valign="bottom"><a class="el" href="c45_8sql__in.html#af5eb174eeecd11233409657221586cf1">c45_classify</a> (text tree_table_name, text classification_table_name, text result_table_name)</td></tr> |
| <tr><td class="mdescLeft"> </td><td class="mdescRight">Classify dataset using trained decision tree model. It runs in quiet mode. The classification result will be stored in the table which is defined as: <a href="#af5eb174eeecd11233409657221586cf1"></a><br/></td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">float8 </td><td class="memItemRight" valign="bottom"><a class="el" href="c45_8sql__in.html#a1b634db47e9006d114da0987e80b9601">c45_score</a> (text tree_table_name, text scoring_table_name, int verbosity)</td></tr> |
| <tr><td class="mdescLeft"> </td><td class="mdescRight">Check the accuracy of the decision tree model. <a href="#a1b634db47e9006d114da0987e80b9601"></a><br/></td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">float8 </td><td class="memItemRight" valign="bottom"><a class="el" href="c45_8sql__in.html#af0739749507c1097003dcf529d29fee2">c45_score</a> (text tree_table_name, text scoring_table_name)</td></tr> |
| <tr><td class="mdescLeft"> </td><td class="mdescRight">Check the accuracy of the decision tree model. <a href="#af0739749507c1097003dcf529d29fee2"></a><br/></td></tr> |
| <tr><td class="memItemLeft" align="right" valign="top">boolean </td><td class="memItemRight" valign="bottom"><a class="el" href="c45_8sql__in.html#ac25e17ecbc70149aa559018e718fc793">c45_clean</a> (text result_tree_table_name)</td></tr> |
| <tr><td class="mdescLeft"> </td><td class="mdescRight">Cleanup the trained tree table and any relevant tables. <a href="#ac25e17ecbc70149aa559018e718fc793"></a><br/></td></tr> |
| </table> |
| <hr/><a name="details" id="details"></a><h2>Detailed Description</h2> |
| <div class="textblock"><dl class="date"><dt><b>Date:</b></dt><dd>April 5, 2012</dd></dl> |
| <dl class="see"><dt><b>See also:</b></dt><dd>For a brief introduction to decision trees, see the module description <a class="el" href="group__grp__dectree.html">Decision Tree</a>. </dd></dl> |
| |
| <p>Definition in file <a class="el" href="c45_8sql__in_source.html">c45.sql_in</a>.</p> |
| </div><hr/><h2>Function Documentation</h2> |
| <a class="anchor" id="afe136e52f498f2ff9e2b91e38e29d670"></a><!-- doxytag: member="c45.sql_in::c45_classify" ref="afe136e52f498f2ff9e2b91e38e29d670" args="(text tree_table_name, text classification_table_name, text result_table_name, int verbosity)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">c45_classify_result c45_classify </td> |
| <td>(</td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>tree_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>classification_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>result_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">int </td> |
| <td class="paramname"><em>verbosity</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">tree_table_name</td><td>The name of trained tree. </td></tr> |
| <tr><td class="paramname">classification_table_name</td><td>The name of the table/view with the source data. </td></tr> |
| <tr><td class="paramname">result_table_name</td><td>The name of result table. </td></tr> |
| <tr><td class="paramname">verbosity</td><td>> 0 means this function runs in verbose mode.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>A c45_classify_result object. </dd></dl> |
| |
| <p>Definition at line <a class="el" href="c45_8sql__in_source.html#l01016">1016</a> of file <a class="el" href="c45_8sql__in_source.html">c45.sql_in</a>.</p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="af5eb174eeecd11233409657221586cf1"></a><!-- doxytag: member="c45.sql_in::c45_classify" ref="af5eb174eeecd11233409657221586cf1" args="(text tree_table_name, text classification_table_name, text result_table_name)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">c45_classify_result c45_classify </td> |
| <td>(</td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>tree_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>classification_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>result_table_name</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <p>CREATE TABLE classification_result ( id INT|BIGINT, class SUPPORTED_DATA_TYPE, prob FLOAT );</p> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">tree_table_name</td><td>The name of trained tree. </td></tr> |
| <tr><td class="paramname">classification_table_name</td><td>The name of the table/view with the source data. </td></tr> |
| <tr><td class="paramname">result_table_name</td><td>The name of result table.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>A c45_classify_result object. </dd></dl> |
| |
| <p>Definition at line <a class="el" href="c45_8sql__in_source.html#l01127">1127</a> of file <a class="el" href="c45_8sql__in_source.html">c45.sql_in</a>.</p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="ac25e17ecbc70149aa559018e718fc793"></a><!-- doxytag: member="c45.sql_in::c45_clean" ref="ac25e17ecbc70149aa559018e718fc793" args="(text result_tree_table_name)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">boolean c45_clean </td> |
| <td>(</td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>result_tree_table_name</em></td><td>)</td> |
| <td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">result_tree_table_name</td><td>The name of the table containing the tree's information.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>The status of that cleanup operation. </dd></dl> |
| |
| <p>Definition at line <a class="el" href="c45_8sql__in_source.html#l01221">1221</a> of file <a class="el" href="c45_8sql__in_source.html">c45.sql_in</a>.</p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a32d2bcbc016c990991d77b6f6148306d"></a><!-- doxytag: member="c45.sql_in::c45_display" ref="a32d2bcbc016c990991d77b6f6148306d" args="(text tree_table, int max_depth)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">set<text> c45_display </td> |
| <td>(</td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>tree_table</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">int </td> |
| <td class="paramname"><em>max_depth</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">tree_table</td><td>The name of the table containing the tree's information. </td></tr> |
| <tr><td class="paramname">max_depth</td><td>The max depth to be displayed. If null, this function will show all levels.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>The text representing the tree with human readable format. </dd></dl> |
| |
| <p>Definition at line <a class="el" href="c45_8sql__in_source.html#l00932">932</a> of file <a class="el" href="c45_8sql__in_source.html">c45.sql_in</a>.</p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="ad7f190eb8e5d53f4772fac699787c0fe"></a><!-- doxytag: member="c45.sql_in::c45_display" ref="ad7f190eb8e5d53f4772fac699787c0fe" args="(text tree_table)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">set<text> c45_display </td> |
| <td>(</td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>tree_table</em></td><td>)</td> |
| <td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">tree_table,:</td><td>The name of the table containing the tree's information.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>The text representing the tree with human readable format. </dd></dl> |
| |
| <p>Definition at line <a class="el" href="c45_8sql__in_source.html#l00981">981</a> of file <a class="el" href="c45_8sql__in_source.html">c45.sql_in</a>.</p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="ac71787c47795b3b0b133cdbd37438242"></a><!-- doxytag: member="c45.sql_in::c45_genrule" ref="ac71787c47795b3b0b133cdbd37438242" args="(text tree_table_name, int verbosity)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">set<text> c45_genrule </td> |
| <td>(</td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>tree_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">int </td> |
| <td class="paramname"><em>verbosity</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">tree_table_name</td><td>The name of the table containing the tree's information. </td></tr> |
| <tr><td class="paramname">verbosity</td><td>If >= 1 will run in verbose mode.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>The rule representation text for a decision tree. </dd></dl> |
| |
| <p>Definition at line <a class="el" href="c45_8sql__in_source.html#l00616">616</a> of file <a class="el" href="c45_8sql__in_source.html">c45.sql_in</a>.</p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="acdba07d3897356a75666aa6d5999f490"></a><!-- doxytag: member="c45.sql_in::c45_genrule" ref="acdba07d3897356a75666aa6d5999f490" args="(text tree_table_name)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">set<text> c45_genrule </td> |
| <td>(</td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>tree_table_name</em></td><td>)</td> |
| <td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">tree_table_name</td><td>The name of the table containing the tree's information.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>The rule representation text for a decision tree. </dd></dl> |
| |
| <p>Definition at line <a class="el" href="c45_8sql__in_source.html#l00900">900</a> of file <a class="el" href="c45_8sql__in_source.html">c45.sql_in</a>.</p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a1b634db47e9006d114da0987e80b9601"></a><!-- doxytag: member="c45.sql_in::c45_score" ref="a1b634db47e9006d114da0987e80b9601" args="(text tree_table_name, text scoring_table_name, int verbosity)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">float8 c45_score </td> |
| <td>(</td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>tree_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>scoring_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">int </td> |
| <td class="paramname"><em>verbosity</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">tree_table_name</td><td>The name of the trained tree. </td></tr> |
| <tr><td class="paramname">scoring_table_name</td><td>The name of the table/view with the source data. </td></tr> |
| <tr><td class="paramname">verbosity</td><td>> 0 means this function runs in verbose mode.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>The estimated accuracy information. </dd></dl> |
| |
| <p>Definition at line <a class="el" href="c45_8sql__in_source.html#l01162">1162</a> of file <a class="el" href="c45_8sql__in_source.html">c45.sql_in</a>.</p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="af0739749507c1097003dcf529d29fee2"></a><!-- doxytag: member="c45.sql_in::c45_score" ref="af0739749507c1097003dcf529d29fee2" args="(text tree_table_name, text scoring_table_name)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">float8 c45_score </td> |
| <td>(</td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>tree_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>scoring_table_name</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">tree_table_name</td><td>The name of the trained tree. </td></tr> |
| <tr><td class="paramname">scoring_table_name</td><td>The name of the table/view with the source data.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>The estimated accuracy information. </dd></dl> |
| |
| <p>Definition at line <a class="el" href="c45_8sql__in_source.html#l01192">1192</a> of file <a class="el" href="c45_8sql__in_source.html">c45.sql_in</a>.</p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a4fbee855d22101d15d195d573189eb98"></a><!-- doxytag: member="c45.sql_in::c45_train" ref="a4fbee855d22101d15d195d573189eb98" args="(text split_criterion, text training_table_name, text result_tree_table_name, text validation_table_name, text continuous_feature_names, text feature_col_names, text id_col_name, text class_col_name, float confidence_level, text how2handle_missing_value, int max_tree_depth, float node_prune_threshold, float node_split_threshold, int verbosity)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">c45_train_result c45_train </td> |
| <td>(</td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>split_criterion</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>training_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>result_tree_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>validation_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>continuous_feature_names</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>feature_col_names</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>id_col_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>class_col_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>confidence_level</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>how2handle_missing_value</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">int </td> |
| <td class="paramname"><em>max_tree_depth</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>node_prune_threshold</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>node_split_threshold</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">int </td> |
| <td class="paramname"><em>verbosity</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">split_criterion</td><td>The name of the split criterion that should be used for tree construction. The valid values are ‘infogain’, ‘gainratio’, and ‘gini’. It can't be NULL. Information gain(infogain) and gini index(gini) are biased toward multivalued attributes. Gain ratio(gainratio) adjusts for this bias. However, it tends to prefer unbalanced splits in which one partition is much smaller than the others. </td></tr> |
| <tr><td class="paramname">training_table_name</td><td>The name of the table/view with the source data. </td></tr> |
| <tr><td class="paramname">result_tree_table_name</td><td>The name of the table where the resulting DT will be kept. </td></tr> |
| <tr><td class="paramname">validation_table_name</td><td>The name of the table/view that contains the validation set used for tree pruning. The default is NULL, in which case we will not do tree pruning. </td></tr> |
| <tr><td class="paramname">continuous_feature_names</td><td>A comma-separated list of the names of features whose values are continuous. The default is null, which means there are no continuous features in the training table. </td></tr> |
| <tr><td class="paramname">feature_col_names</td><td>A comma-separated list of the names of table columns, each of which defines a feature. The default value is null, which means all the columns in the training table, except columns named ‘id’ and ‘class’, will be used as features. </td></tr> |
| <tr><td class="paramname">id_col_name</td><td>The name of the column containing an ID for each record. </td></tr> |
| <tr><td class="paramname">class_col_name</td><td>The name of the column containing the labeled class. </td></tr> |
| <tr><td class="paramname">confidence_level</td><td>A statistical confidence interval of the resubstitution error. </td></tr> |
| <tr><td class="paramname">how2handle_missing_value</td><td>The way to handle missing value. The valid value is 'explicit' or 'ignore'. </td></tr> |
| <tr><td class="paramname">max_tree_depth</td><td>Specifies the maximum number of levels in the result DT to avoid overgrown DTs. </td></tr> |
| <tr><td class="paramname">node_prune_threshold</td><td>The minimum percentage of the number of records required in a child node. It can't be NULL. The range of it is in [0.0, 1.0]. This threshold only applies to the non-root nodes. Therefore, if its value is 1, then the trained tree only has one node (the root node); if its value is 0, then no nodes will be pruned by this parameter. </td></tr> |
| <tr><td class="paramname">node_split_threshold</td><td>The minimum percentage of the number of records required in a node in order for a further split to be possible. It can't be NULL. The range of it is in [0.0, 1.0]. If it's value is 1, then the trained tree only has two levels, since only the root node can grow; if its value is 0, then trees can grow extensively. </td></tr> |
| <tr><td class="paramname">verbosity</td><td>> 0 means this function runs in verbose mode.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>An c45_train_result object. </dd></dl> |
| |
| <p>Definition at line <a class="el" href="c45_8sql__in_source.html#l00365">365</a> of file <a class="el" href="c45_8sql__in_source.html">c45.sql_in</a>.</p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a6c039416b94686b915e2a4c1133a5d44"></a><!-- doxytag: member="c45.sql_in::c45_train" ref="a6c039416b94686b915e2a4c1133a5d44" args="(text split_criterion, text training_table_name, text result_tree_table_name, text validation_table_name, text continuous_feature_names, text feature_col_names, text id_col_name, text class_col_name, float confidence_level, text how2handle_missing_value)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">c45_train_result c45_train </td> |
| <td>(</td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>split_criterion</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>training_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>result_tree_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>validation_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>continuous_feature_names</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>feature_col_names</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>id_col_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>class_col_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">float </td> |
| <td class="paramname"><em>confidence_level</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>how2handle_missing_value</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">split_criterion</td><td>The name of the split criterion that should be used for tree construction. Possible values are ‘gain’, ‘gainratio’, and ‘gini’. </td></tr> |
| <tr><td class="paramname">training_table_name</td><td>The name of the table/view with the source data. </td></tr> |
| <tr><td class="paramname">result_tree_table_name</td><td>The name of the table where the resulting DT will be kept. </td></tr> |
| <tr><td class="paramname">validation_table_name</td><td>The name of the table/view that contains the validation set used for tree pruning. The default is NULL, in which case we will not do tree pruning. </td></tr> |
| <tr><td class="paramname">continuous_feature_names</td><td>A comma-separated list of the names of features whose values are continuous. The default is null, which means there are no continuous features in the training table. </td></tr> |
| <tr><td class="paramname">feature_col_names</td><td>A comma-separated list of the names of table columns, each of which defines a feature. The default value is null, which means all the columns in the training table, except columns named ‘id’ and ‘class’, will be used as features. </td></tr> |
| <tr><td class="paramname">id_col_name</td><td>The name of the column containing an ID for each record. </td></tr> |
| <tr><td class="paramname">class_col_name</td><td>The name of the column containing the labeled class. </td></tr> |
| <tr><td class="paramname">confidence_level</td><td>A statistical confidence interval of the resubstitution error. </td></tr> |
| <tr><td class="paramname">how2handle_missing_value</td><td>The way to handle missing value. The valid value is 'explicit' or 'ignore'.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>An c45_train_result object.</dd></dl> |
| <dl class="note"><dt><b>Note:</b></dt><dd>This calls the long form of C45 with the following default parameters:<ul> |
| <li>max_tree_deapth := 10</li> |
| <li>node_prune_threshold := 0.001</li> |
| <li>node_split_threshold := 0.01</li> |
| <li>verbosity := 0 </li> |
| </ul> |
| </dd></dl> |
| |
| <p>Definition at line <a class="el" href="c45_8sql__in_source.html#l00512">512</a> of file <a class="el" href="c45_8sql__in_source.html">c45.sql_in</a>.</p> |
| |
| </div> |
| </div> |
| <a class="anchor" id="a18b30ff1a063e7cd16274bf7ab2a71dc"></a><!-- doxytag: member="c45.sql_in::c45_train" ref="a18b30ff1a063e7cd16274bf7ab2a71dc" args="(text split_criterion, text training_table_name, text result_tree_table_name)" --> |
| <div class="memitem"> |
| <div class="memproto"> |
| <table class="memname"> |
| <tr> |
| <td class="memname">c45_train_result c45_train </td> |
| <td>(</td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>split_criterion</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>training_table_name</em>, </td> |
| </tr> |
| <tr> |
| <td class="paramkey"></td> |
| <td></td> |
| <td class="paramtype">text </td> |
| <td class="paramname"><em>result_tree_table_name</em> </td> |
| </tr> |
| <tr> |
| <td></td> |
| <td>)</td> |
| <td></td><td></td> |
| </tr> |
| </table> |
| </div> |
| <div class="memdoc"> |
| <dl><dt><b>Parameters:</b></dt><dd> |
| <table class="params"> |
| <tr><td class="paramname">split_criterion</td><td>The name of the split criterion that should be used for tree construction. Possible values are ‘gain’, ‘gainratio’, and ‘gini’. </td></tr> |
| <tr><td class="paramname">training_table_name</td><td>The name of the table/view with the source data. </td></tr> |
| <tr><td class="paramname">result_tree_table_name</td><td>The name of the table where the resulting DT will be kept.</td></tr> |
| </table> |
| </dd> |
| </dl> |
| <dl class="return"><dt><b>Returns:</b></dt><dd>An c45_train_result object.</dd></dl> |
| <dl class="note"><dt><b>Note:</b></dt><dd>This calls the above short form of C45 with the following default parameters:<ul> |
| <li>validation_table_name := NULL</li> |
| <li>continuous_feature_names := NULL</li> |
| <li>id_column_name := 'id'</li> |
| <li>class_column_name := 'class'</li> |
| <li>confidence_level := 25</li> |
| <li>how2handle_missing_value := 'explicit'</li> |
| <li>max_tree_deapth := 10</li> |
| <li>node_prune_threshold := 0.001</li> |
| <li>node_split_threshold := 0.01</li> |
| <li>verbosity := 0 </li> |
| </ul> |
| </dd></dl> |
| |
| <p>Definition at line <a class="el" href="c45_8sql__in_source.html#l00578">578</a> of file <a class="el" href="c45_8sql__in_source.html">c45.sql_in</a>.</p> |
| |
| </div> |
| </div> |
| </div> |
| </div> |
| <div id="nav-path" class="navpath"> |
| <ul> |
| <li class="navelem"><a class="el" href="c45_8sql__in.html">c45.sql_in</a> </li> |
| <!-- window showing the filter options --> |
| <div id="MSearchSelectWindow" |
| onmouseover="return searchBox.OnSearchSelectShow()" |
| onmouseout="return searchBox.OnSearchSelectHide()" |
| onkeydown="return searchBox.OnSearchSelectKey(event)"> |
| <a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark"> </span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark"> </span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark"> </span>Functions</a></div> |
| |
| <!-- iframe showing the search results (closed by default) --> |
| <div id="MSearchResultsWindow"> |
| <iframe src="javascript:void(0)" frameborder="0" |
| name="MSearchResults" id="MSearchResults"> |
| </iframe> |
| </div> |
| |
| |
| <li class="footer">Generated on Tue Apr 2 2013 14:57:03 for MADlib by |
| <a href="http://www.doxygen.org/index.html"> |
| <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.5.1 </li> |
| </ul> |
| </div> |
| |
| |
| </body> |
| </html> |