|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--edu.uiuc.ge.illigal.gale.agents.DTAgent
Implements the generic handle to Agents for Induction Trees.
Field Summary | |
protected edu.uiuc.ge.illigal.gale.data.Attribute |
aAtt
The attribute used |
protected edu.uiuc.ge.illigal.gale.agents.AgentPerformance |
agnPer
Agent Performance object |
protected edu.uiuc.ge.illigal.gale.data.AttributeSet |
attCnf
The attributes set information object |
protected float |
fThres
The threshold for real attribute classification |
protected edu.uiuc.ge.illigal.gale.config.GALEConfiguration |
galeCnf
The GALE environment configuration object |
protected int |
iCls
The class if the node is a leaf |
protected int |
iIndex
The index of the attribute used |
protected java.util.Random |
rnd
Random number generator object |
protected java.util.Vector |
vecChild
The Agent's children |
Constructor Summary | |
DTAgent()
Builds a simple agent with null information |
|
DTAgent(edu.uiuc.ge.illigal.gale.config.GALEConfiguration gale,
edu.uiuc.ge.illigal.gale.data.AttributeSet att)
Builds a simple agent. |
Method Summary | |
protected void |
addChild(edu.uiuc.ge.illigal.gale.agents.DTAgent agnChild)
Adds a new Agent child. |
protected void |
addChild(edu.uiuc.ge.illigal.gale.agents.DTAgent agnChild,
int iPos)
Adds a new Agent child. |
protected float |
boundedFloat(float lb,
float ub)
Generates a random bounded float using the random number generator. |
edu.uiuc.ge.illigal.gale.agents.Agent |
buildAgent(edu.uiuc.ge.illigal.gale.config.GALEConfiguration galeCnf,
edu.uiuc.ge.illigal.gale.data.AttributeSet att)
Returns a random builded agent. |
protected static edu.uiuc.ge.illigal.gale.agents.DTAgent |
buildDTAgent(edu.uiuc.ge.illigal.gale.config.GALEConfiguration galeCnf,
edu.uiuc.ge.illigal.gale.data.AttributeSet attSet,
int iDepth)
Builds an Agent Hierarchical Aggregate. |
int |
classify(edu.uiuc.ge.illigal.gale.data.Instance ins)
Classifies the given instance |
java.lang.Object |
clone()
Clones the handled agent. |
float |
complexity()
Returns a complexity measure. |
protected int |
countLeafNodes()
Count the number of leaf agents in the tree |
protected int |
countNodes()
Count the number of nodes in the tree |
protected edu.uiuc.ge.illigal.gale.agents.DTAgent |
getChild(int iChild)
Returns the requested child. |
protected int |
getChildNumber()
Returns the number of agent childs. |
protected edu.uiuc.ge.illigal.gale.agents.DTAgent |
getIthNode(edu.uiuc.ge.illigal.gale.agents.DTAgent agn,
int iNode)
Returns the ith agent in the tree |
edu.uiuc.ge.illigal.gale.agents.AgentPerformance |
getPerformance()
Provides the classification performance information. |
protected java.lang.String |
getStarTree()
Returns the star tree. |
protected java.lang.String |
getStringModel(java.lang.String pre)
Returns the stringfied model for the agent. |
static void |
main(java.lang.String[] sArgs)
|
edu.uiuc.ge.illigal.gale.agents.Agent |
merge(edu.uiuc.ge.illigal.gale.agents.Agent agn)
Merges two agents. |
protected void |
mutateGenotype()
Mutates the genetic information contained in the tree |
edu.uiuc.ge.illigal.gale.agents.Agent |
prune()
Clean spurious issues. |
protected void |
removeAllChilds()
Remove all children |
protected void |
removeChild(int iPos)
Remove the ith Child. |
void |
resetPerformance()
Resets the agents' performance. |
edu.uiuc.ge.illigal.gale.agents.Agent |
split()
Splits an agent |
protected void |
swapChildren(edu.uiuc.ge.illigal.gale.agents.DTAgent agn)
Exchange children |
java.lang.String |
toString()
Returns the stringfied form of the agent |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
protected edu.uiuc.ge.illigal.gale.config.GALEConfiguration galeCnf
protected edu.uiuc.ge.illigal.gale.data.AttributeSet attCnf
protected float fThres
protected edu.uiuc.ge.illigal.gale.data.Attribute aAtt
protected int iIndex
protected int iCls
protected java.util.Vector vecChild
protected edu.uiuc.ge.illigal.gale.agents.AgentPerformance agnPer
protected java.util.Random rnd
Constructor Detail |
public DTAgent()
public DTAgent(edu.uiuc.ge.illigal.gale.config.GALEConfiguration gale, edu.uiuc.ge.illigal.gale.data.AttributeSet att)
gale
- The GALE configurationatt
- The instance data information usedMethod Detail |
public edu.uiuc.ge.illigal.gale.agents.Agent buildAgent(edu.uiuc.ge.illigal.gale.config.GALEConfiguration galeCnf, edu.uiuc.ge.illigal.gale.data.AttributeSet att)
Agent
buildAgent
in interface Agent
galeCnf
- The GALE configuration objectatt
- The attributes set information object
protected static edu.uiuc.ge.illigal.gale.agents.DTAgent buildDTAgent(edu.uiuc.ge.illigal.gale.config.GALEConfiguration galeCnf, edu.uiuc.ge.illigal.gale.data.AttributeSet attSet, int iDepth)
galeCnf
- The GALE environment configuration objectattSet
- The attribute set information objectiDepth
- The Agent depth
public edu.uiuc.ge.illigal.gale.agents.AgentPerformance getPerformance()
Agent
getPerformance
in interface Agent
public void resetPerformance()
Agent
resetPerformance
in interface Agent
public edu.uiuc.ge.illigal.gale.agents.Agent merge(edu.uiuc.ge.illigal.gale.agents.Agent agn)
Agent
merge
in interface Agent
agn
- The second agent to be merged
protected void swapChildren(edu.uiuc.ge.illigal.gale.agents.DTAgent agn)
agn
- The other DTAgent to exchange childrenprotected edu.uiuc.ge.illigal.gale.agents.DTAgent getIthNode(edu.uiuc.ge.illigal.gale.agents.DTAgent agn, int iNode)
public edu.uiuc.ge.illigal.gale.agents.Agent split()
Agent
split
in interface Agent
protected void mutateGenotype()
public java.lang.Object clone() throws java.lang.CloneNotSupportedException
Agent
clone
in interface Agent
clone
in class java.lang.Object
java.lang.CloneNotSupportedException
- Thrown when the agent cannot be
clonedpublic float complexity()
Agent
complexity
in interface Agent
public edu.uiuc.ge.illigal.gale.agents.Agent prune()
Agent
prune
in interface Agent
public int classify(edu.uiuc.ge.illigal.gale.data.Instance ins)
Agent
classify
in interface Agent
public java.lang.String toString()
Agent
toString
in interface Agent
toString
in class java.lang.Object
protected java.lang.String getStringModel(java.lang.String pre)
pre
- the current prefix
protected java.lang.String getStarTree()
protected float boundedFloat(float lb, float ub)
lb
- lower boundub
- upper boundprotected void addChild(edu.uiuc.ge.illigal.gale.agents.DTAgent agnChild)
agnChild
- The Agent to be addedprotected void addChild(edu.uiuc.ge.illigal.gale.agents.DTAgent agnChild, int iPos)
agnChild
- The Agent to be addediPos
- The child position to be addedprotected void removeChild(int iPos)
iPos
- The child position to be removedprotected void removeAllChilds()
protected edu.uiuc.ge.illigal.gale.agents.DTAgent getChild(int iChild)
iChild
- The requested Agent child
protected int getChildNumber()
protected int countNodes()
protected int countLeafNodes()
public static void main(java.lang.String[] sArgs)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |