public class BayesianTable
extends java.lang.Object
implements java.io.Serializable
| Constructor and Description |
|---|
BayesianTable(BayesianEvent theEvent) |
| Modifier and Type | Method and Description |
|---|---|
void |
addLine(double prob,
boolean result,
boolean... args)
Add a new line.
|
void |
addLine(double prob,
int result,
boolean... args)
Add a new line.
|
void |
addLine(double prob,
int result,
int... args)
Add a new line.
|
TableLine |
findLine(int result,
int[] args)
Find the specified truth table line.
|
int |
generateRandom(int... args)
Generate a random sampling based on this truth table.
|
java.util.List<TableLine> |
getLines() |
int |
getMaxLines() |
void |
reset()
Reset the truth table to zero.
|
java.lang.String |
toString() |
void |
validate()
Validate the truth table.
|
public BayesianTable(BayesianEvent theEvent)
public void reset()
public void addLine(double prob,
boolean result,
boolean... args)
prob - The probability.result - The resulting probability.args - The arguments.public void addLine(double prob,
int result,
boolean... args)
prob - The probability.result - The resulting probability.args - The arguments.public void addLine(double prob,
int result,
int... args)
prob - The probability.result - The resulting probability.args - The arguments.public void validate()
public int generateRandom(int... args)
args - The arguemtns.public java.lang.String toString()
toString in class java.lang.Objectpublic java.util.List<TableLine> getLines()
public TableLine findLine(int result, int[] args)
result - The result sought.args - The arguments.public int getMaxLines()