|Consult Manual Page
consult - classify items using a decision tree
consult [ -f FNS ] [ -t ]
Consult reads a decision tree produced by c4.5 and uses this to classify items whose description is provided by the user. The decision tree read is filestem.tree, where filestem is the file name stem (see c4.5(1)).
Consult prompts for the value of an attribute when needed. Unknown attribute values are specified as "?".
If the attribute has discrete values, its value can be specified either as
where v is one of the permissible values of the attribute, or as
v1:p1, v2:p2, ... , vn:pn
where the vi's are some or all of the permissible values of the attribute and the pi's are corresponding probabilities. If the sum of the pi's is less than 1, the remaining probability is distributed equally among the unspecified values of the attribute. For example, if attribute A has possible values X, Y and Z, the reply
is the same as
X:0.5, Y:0.25, Z:0.25
If the attribute has real values, its value can be specified either as
where r is a real number, or as
r1 - r2
where r1 and r2 are real numbers. The latter form is taken to mean "somewhere in the interval [r1,r2]".
To display the subtree of the decision tree with the current node at the root, "?t" may be entered in response to a request for an attribute value.
When all relevant attributes have been determined, consult will give one or more classes that the item might belong to. The likelihood of a class may be indicated by a probability, followed sometimes by a probability interval. For example,
C1 CF = 0.9 [0.85 - 1]
means "class C1 with probability in the interval 0.85 - 1, and with best guess probability 0.9".
At the end of each item, consult will prompt for retrial of the same item, a new item, or end of session. When retrying an item, the previous values of queried attributes are displayed in square brackets. If the value is unchanged, reply with a carriage return; otherwise, specify the changed value.
Options and their meanings are:
-f filestem Specify the filename stem (default DF) -t Display the decision tree at the start of the consulting session.