|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--k2.K2
K2 algorithm------learning Bayes Networks from data Based on : Cooper, G F, Herskovits, E (1992). "A Bayesian Method for the Induction of %Probabilistic Networks from Data" Machine Learning Vol. 9 pp. 309-347 Input: An input datafile which contains <1> a set of n nodes <2> an ordering on the nodes <3> an upper bound u on the number of parents a node may have <4> a database D contains m cases Output: Learn the parent nodes for each nodes and return an XMLBIF file representing the learned Bayesian Network Copyright: Copyright (c) 2001 Company: KSU / KDD
| Constructor Summary | |
K2(K2Manager manager,
java.util.Vector order)
K2 constructor - responsible for building the new network shell with the given order and setting up K2 to run. |
|
| Method Summary | |
static java.util.Vector |
extractOrder(BBN network,
java.lang.String[] args,
int offset)
loads an ordering from the command console (or an array of strings) |
int[][] |
getData()
returns the raw data array. |
BBN |
getNetwork()
getNetwork returns K2's version of the network. |
BBN |
learnNetwork()
learnNetwork is the main driver for K2. |
static void |
main(java.lang.String[] args)
A console utility that runs K2 on the specified network and returns the learned network to the specified output file, given the specieid order. |
void |
reOrderNodes()
reOrderNodes will put the nodes back in the original order. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public K2(K2Manager manager,
java.util.Vector order)
manager - - the network manager that will contain the training
examples and other importnant information.order - - a vector of Integer objects that specifies which order
to set the nodes up.| Method Detail |
public BBN getNetwork()
public static void main(java.lang.String[] args)
public BBN learnNetwork()
public int[][] getData()
public void reOrderNodes()
public static java.util.Vector extractOrder(BBN network,
java.lang.String[] args,
int offset)
network - - the network to check sizeargs - - the args to load fromoffset - - where the ordering starts at in the array
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||