org.processmining.analysis.decisionmining
Class DecisionMiningLogTrace

java.lang.Object
  extended by org.processmining.analysis.decisionmining.DecisionMiningLogTrace

public class DecisionMiningLogTrace
extends java.lang.Object

Records additional information related to the decision points of the connected process model for one Process instance (i.e., records which alternative paths have been taken in this trace).

Author:
arozinat

Constructor Summary
DecisionMiningLogTrace(ProcessInstance pi)
          Create a diagnostic log trace by copying the ordinary process instance.
 
Method Summary
 void addDecisionOccurrences(java.lang.String branchName, java.lang.Integer value)
          Increment the corresponding entry by the specified value.
 ProcessInstance getProcessInstance()
          Retrieves the process instance represented by this log trace.
 void incrementDecisionOccurrences(java.lang.String branchName)
          The increment of the corresponding missingTokens entry is assumed to be 1.
 void initDiagnosticDataStructures(java.util.List<DecisionPoint> decisionPoints)
          Initializes the diagnostic entry for each branch of each decision point with 0.
 weka.core.Instance makeInstance(weka.core.Instances dataset, int attInfoSize)
          Creates a learning instance that can be used by a weka data mining algorithm.
 java.lang.String toString()
          Returns the name of this process instance.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DecisionMiningLogTrace

public DecisionMiningLogTrace(ProcessInstance pi)
Create a diagnostic log trace by copying the ordinary process instance.

Parameters:
pi - the template process instance used to create the diagnostic log trace
Method Detail

getProcessInstance

public ProcessInstance getProcessInstance()
Retrieves the process instance represented by this log trace.

Returns:
the belonging process instance from the log

initDiagnosticDataStructures

public void initDiagnosticDataStructures(java.util.List<DecisionPoint> decisionPoints)
Initializes the diagnostic entry for each branch of each decision point with 0.

Parameters:
decisionPoints - the list of decision points for which the taken branches will be recorded

addDecisionOccurrences

public void addDecisionOccurrences(java.lang.String branchName,
                                   java.lang.Integer value)
                            throws java.lang.Exception
Increment the corresponding entry by the specified value.

Parameters:
branchName - the name of the decision branch to be updated
value - the value to be added to the current value
Throws:
java.lang.Exception - in the case that the specified entry is missing

incrementDecisionOccurrences

public void incrementDecisionOccurrences(java.lang.String branchName)
                                  throws java.lang.Exception
The increment of the corresponding missingTokens entry is assumed to be 1.

Parameters:
branchName - the name of the decision branch to be updated
Throws:
java.lang.Exception

toString

public java.lang.String toString()
Returns the name of this process instance.

Overrides:
toString in class java.lang.Object

makeInstance

public weka.core.Instance makeInstance(weka.core.Instances dataset,
                                       int attInfoSize)
Creates a learning instance that can be used by a weka data mining algorithm. Note that loop semantics are not yet taken into account, therefore each trace is exactly represented by one learning instance.

Parameters:
dataset - the enclosing data set
attInfoSize - the number of attributes (including the class attribute) specified by the instance
Returns:
the learning instance representing this log trace