oracle.dmt.odm.transformation
Class Transformation

java.lang.Object
  |
  +--oracle.dmt.odm.MiningObject
        |
        +--oracle.dmt.odm.transformation.Transformation
All Implemented Interfaces:
java.io.Serializable

public class Transformation
extends MiningObject

An instance of Transformation is used to prepare input data for use in data mining operations in ODM. It provides two static methods to perform the following tasks related to discretization (binning):

  1. Create discretization tables, given discretization details.
  2. Create a discretized version of a database table using the discretization tables specified.

See Also:
Serialized Form

Constructor Summary
Transformation()
           
 
Method Summary
TypeMethod
static void createDiscretizationTables(Connection msConnection, LocationAccessData inputDataLocation, PhysicalDataSpecification pds, DiscretizationSpecification[] binningDetails, java.lang.String numericDiscretizationTableName, java.lang.String categoricalDiscretizationTableName, java.lang.String discretizationTablesSchemaName)
          Creates discretization tables for the specified data table.
static void createPhysicalTables(Connection msConnection, java.lang.String numericDiscretizationTableName, java.lang.String categoricalDiscretizationTableName, java.lang.String discretizationTablesSchemaName)
           
static void discretize(java.sql.Connection dbConn, LocationAccessData inputDataLocation, PhysicalDataSpecification pds, java.lang.String numericDiscretizationTableName, java.lang.String categoricalDiscretizationTableName, java.lang.String discretizationTablesSchemaName, LocationAccessData resultViewLocation)
          Deprecated. As of ODM 9.2.0. Use other discretize method.
static void discretize(Connection dmsConn, LocationAccessData inputDataLocation, PhysicalDataSpecification pds, java.lang.String numericDiscretizationTableName, java.lang.String categoricalDiscretizationTableName, java.lang.String discretizationTablesSchemaName, LocationAccessData resultViewLocation)
          Creates a view in the specified location using the discretization tables provided as input.
static void discretize(Connection dmsConn, LocationAccessData inputDataLocation, PhysicalDataSpecification pds, java.lang.String numericDiscretizationTableName, java.lang.String categoricalDiscretizationTableName, java.lang.String discretizationTablesSchemaName, LocationAccessData resultViewLocation, boolean openEndedNumericalDiscretization)
          Creates a view in the specified location using the discretization tables provided as input.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Transformation

public Transformation()
Method Detail

createPhysicalTables

public static void createPhysicalTables(Connection msConnection,
                                        java.lang.String numericDiscretizationTableName,
                                        java.lang.String categoricalDiscretizationTableName,
                                        java.lang.String discretizationTablesSchemaName)
                                 throws java.sql.SQLException

createDiscretizationTables

public static void createDiscretizationTables(Connection msConnection,
                                              LocationAccessData inputDataLocation,
                                              PhysicalDataSpecification pds,
                                              DiscretizationSpecification[] binningDetails,
                                              java.lang.String numericDiscretizationTableName,
                                              java.lang.String categoricalDiscretizationTableName,
                                              java.lang.String discretizationTablesSchemaName)
                                       throws java.sql.SQLException,
                                              InvalidArgumentException
Creates discretization tables for the specified data table. Discretization details (such as categories or number of bins, etc.) must be specified as inputs. Only the attributes that are to be binned must be specified. Once created, the discretization tables can be changed as needed.
Parameters:
msConnection - Mining server connection handle.
inputDataLocation - Location of the input data (table to be discretized)
pds - PhysicalDataSpecification Transactional or nontransactional
binningDetails - Array of DiscretizationSpecification for the attributes to be binned
numericDiscretizationTableName - Name of the output numeric discretization table
categoricalDiscretizationTableName - Name of the output categorical discretization table
discretizationTablesSchemaName - Schema where both the categorical and numberical discretization tables will be created
Throws:
java.sql.SQLException - Thrown if a database error occurs while creating the discretization tables
InvalidArgumentException - thrown if an invalid input is specified

discretize

public static void discretize(java.sql.Connection dbConn,
                              LocationAccessData inputDataLocation,
                              PhysicalDataSpecification pds,
                              java.lang.String numericDiscretizationTableName,
                              java.lang.String categoricalDiscretizationTableName,
                              java.lang.String discretizationTablesSchemaName,
                              LocationAccessData resultViewLocation)
                       throws java.sql.SQLException,
                              InvalidArgumentException
Deprecated. As of ODM 9.2.0. Use other discretize method.

Creates a view in the specified location identified using the discretization tables specified. If an attribute has no discretization details, the attribute is carried forward as is. For numerical attributes, the lower bin boundary is always included in the bin; the upper boundary is excluded, excpet for the last bin (largest boundary value). Existing nulls are carried forward. Numerical outliers are assigned a null value. Categorical outliers are all assigned to the Other bin.
Parameters:
dbConn - A database connection to the data mining server
inputDataLocation - The location of the input data
pds - An instance of PhysicalDataSpecification that describes the input data
numericDiscretizationTableName - The name of the numeric discretization table used for binning
categoricalDiscretizationTableName - The name of the categorical discretization table used for binning
discretizationTablesSchemaName - The schema where both (categorical and numberical) discretization tables exist
resultViewLocation - The location of the output discretized view
Throws:
java.sql.SQLException - when an error occurs during discretization of the input data.
InvalidArgumentException -
  • when inputDataLocation is null,
  • when numericDiscretizationTableName is null,
  • when categoricalDiscretizationTableName is null, or
  • when resultViewLocation is null.

discretize

public static void discretize(Connection dmsConn,
                              LocationAccessData inputDataLocation,
                              PhysicalDataSpecification pds,
                              java.lang.String numericDiscretizationTableName,
                              java.lang.String categoricalDiscretizationTableName,
                              java.lang.String discretizationTablesSchemaName,
                              LocationAccessData resultViewLocation)
                       throws java.sql.SQLException,
                              InvalidArgumentException
Creates a view in the specified location using the discretization tables provided as input. If an attribute has no discretization details, the attribute is carried forward as is. For numerical attributes, the lower bin boundary is always included in the bin; the upper boundary is excluded, excpet for the last bin (largest boundary value). Existing nulls are carried forward. Numerical outliers are assigned a null value. Categorical outliers are all assigned to the Other bin.
Parameters:
dmsConn - A connection to the data mining server
inputDataLocation - The location of the input data
pds - An instance of PhysicalDataSpecification that describes the input data
numericDiscretizationTableName - The name of the numeric discretization table used for binning
categoricalDiscretizationTableName - The name of the categorical discretization table used for binning
discretizationTablesSchemaName - The schema where both (categorical and numberical) discretization tables exist
resultViewLocation - The location of the output discretized view
Throws:
java.sql.SQLException - when an error occurs during discretization of the input data.
InvalidArgumentException -
  • when inputDataLocation is null,
  • when numericDiscretizationTableName is null,
  • when categoricalDiscretizationTableName is null, or
  • when resultViewLocation is null.

discretize

public static void discretize(Connection dmsConn,
                              LocationAccessData inputDataLocation,
                              PhysicalDataSpecification pds,
                              java.lang.String numericDiscretizationTableName,
                              java.lang.String categoricalDiscretizationTableName,
                              java.lang.String discretizationTablesSchemaName,
                              LocationAccessData resultViewLocation,
                              boolean openEndedNumericalDiscretization)
                       throws java.sql.SQLException,
                              InvalidArgumentException
Creates a view in the specified location using the discretization tables provided as input. If an attribute has no discretization details, the attribute is carried forward as is. For numerical attributes, the lower bin boundary is always included in the bin; the upper boundary is excluded, excpet for the last bin (largest boundary value). Existing nulls are carried forward. Numerical outliers are assigned a null value. Categorical outliers are all assigned to the "Other" bin. If openEndedNumericalDiscretization is true: For numerical attributes, lowest and highest bins are open ended. Categorical handling is the same as the one described above.
Parameters:
dmsConn - A connection to the data mining server
inputDataLocation - The location of the input data
pds - An instance of PhysicalDataSpecification that describes the input data
numericDiscretizationTableName - The name of the numeric discretization table used for binning
categoricalDiscretizationTableName - The name of the categorical discretization table used for binning
discretizationTablesSchemaName - The schema where both (categorical and numberical) discretization tables exist
resultViewLocation - The location of the output discretized view
openEndedNumericalDiscretization - Specifies open-ended handling for the numerical attributes
Throws:
java.sql.SQLException - when an error occurs during discretization of the input data.
InvalidArgumentException -
  • when inputDataLocation is null,
  • when numericDiscretizationTableName is null,
  • when categoricalDiscretizationTableName is null, or
  • when resultViewLocation is null.