Oracle Data Mining Java API Reference
10g Release 1 (10.1)

B12276-01

oracle.dmt.odm.task
Class MiningApplyTask

java.lang.Object
  |
  +--oracle.dmt.odm.MiningObject
        |
        +--oracle.dmt.odm.LocatableObject
              |
              +--oracle.dmt.odm.task.MiningTask
                    |
                    +--oracle.dmt.odm.task.MiningDataTask
                          |
                          +--oracle.dmt.odm.task.MiningApplyTask
All Implemented Interfaces:
java.io.Serializable

public class MiningApplyTask
extends MiningDataTask

An instance of MiningApplyTask is used for applying a model to a data set to make predictions, classifications, and to provide associated probabilities. The apply task can be performed using any supervised model or clustering model supported by ODM.

ODM supports flexible ways to create the apply output table. The MiningApplyOutput (MAO) object is used to specify the apply output table format using ApplyContentItem. The MAO provides the ability to specify the computation of top N scores of the target attribute and associated probability. It also provides the user the ability to specify the computation of probability of a specified target attribute category (a.k.a class value).

The input data for a MiningApplyTask must have all the active attributes used in building the associated supervised model. Input data must also have all source attributes specified in the MAO. If the task input data is not compatible with the specified input model and MAO, the execution of apply task fails with an exception.

After constructing a valid MiningApplyTask instance, the task must be persisted in the database using store(dmsConn, taskName) method before executing. The task name must be unique in the in the user schema task name space.

After successful completion of the apply task, the apply output table will be avaliable in the user-specified location. MiningApplyResults object can be used to retrieve the result details of the apply task. To remove the mining apply task object in the database, call the remove(dmsConn, taskName) method.

Since:
ODM 9.2.0
See Also:
Serialized Form

Constructor Summary
MiningApplyTask(PhysicalDataSpecification taskInputData, java.lang.String inputModelName, MiningApplyOutput applyOutput, LocationAccessData applyOutputLoc, java.lang.String applyResultName)
          Creates an instance of the apply task from the given mining data (as a set of records), the model to which the data is applied, and the apply output.

 

Method Summary
 MiningApplyOutput getApplyOutput()
          Returns the apply output specification used in performing the apply operation.
 java.lang.String getApplyResultName()
          Returns the apply result name.
 LocationAccessData getOutputDataLocation()
          Returns location of the apply output table.
static MiningApplyTask restore(Connection dmsConn, java.lang.String taskName)
          Restores the user-specified mining apply task object from the database.

 

Methods inherited from class oracle.dmt.odm.task.MiningDataTask
getInputModelName, getTaskInputData

 

Methods inherited from class oracle.dmt.odm.task.MiningTask
execute, getActiveExecutionHandle, getCurrentStatus, getExecutionDuration, getExecutionHandle, getLatestExecutionHandle, getName, getStatusHistory, getTaskType, getType, listTasks, remove, rename, store, terminate, waitForCompletion, waitForCompletion

 

Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Constructor Detail

MiningApplyTask

public MiningApplyTask(PhysicalDataSpecification taskInputData,
                       java.lang.String inputModelName,
MiningApplyOutput applyOutput,
LocationAccessData applyOutputLoc,
                       java.lang.String applyResultName)
                throws InvalidArgumentException,
ODMException
Creates an instance of the apply task from the given mining data (as a set of records), the model to which the data is applied, and the apply output.
Parameters:
taskInputData - Physical data specification of the input data
inputModelName - Input mining model name in the data mining server
applyOutput - Apply output specification. For more details refer to oracle.dmt.odm.result.MiningApplyOutput
applyResultName - Apply result name
Throws:
InvalidArgumentException - is thrown
- when any of the input arguments are null
- when the inputModelName/applyResultName length >25 bytes
- when the taskInputData does not have location access data
- when the applyOutput is not valid
InvalidArgumentException
ODMException
Method Detail

getApplyOutput

public MiningApplyOutput getApplyOutput()
Returns the apply output specification used in performing the apply operation.
Returns:
apply output object

getApplyResultName

public java.lang.String getApplyResultName()
Returns the apply result name.
Returns:
apply result name.

getOutputDataLocation

public LocationAccessData getOutputDataLocation()
Returns location of the apply output table. This table is created once the apply task is successful.
Returns:
apply output table location.

restore

public static MiningApplyTask restore(Connection dmsConn,
                                      java.lang.String taskName)
                                                   throws InvalidArgumentException,
MiningTaskException,
                                                          java.sql.SQLException,
ODMException
Restores the user-specified mining apply task object from the database.
Parameters:
dmsConn - Data mining server connection.
taskName - Name of the apply task.
Returns:
Restored mining apply task.
Throws:
InvalidArgumentException - is thrown
- when the dmsConn/taskName are null
- when the taskName length >64 characters
MiningTaskException - is thrown
- when the restore fails
SQLException - is thrown
- when there is a failure in JDBC calls
InvalidArgumentException
MiningTaskException
java.sql.SQLException
ODMException

Copyright © 2003 Oracle Corporation. All Rights Reserved.