|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--oracle.dmt.odm.MiningObject | +--oracle.dmt.odm.data.LogicalDataSpecification
An instance of LogicalDataSpecification
(LDS) is used to describe
the logical characteristics of the data used in model building, and
is composed of a set of mining attributes.
The mining attributes contained in an LDS must have unique names.
An instance of LogicalDataSpecification
can be constructed in two ways:
LogicalDataSpecification
object, then add
mining attributes. For example:
LogicalDataSpecification lds = new LogicalDataSpecification();
lds.addAttribute( mAttr1 );
lds.addAttribute( mAttr2 );
...
LogicalDataSpecification
object using the
create
utility method, which creates the LDS based on an input table. The user can
use either transactional or non-transactional tables. For example:
LogicalDataSpecification lds =
LogicalDataSpecification.create(dmsConn, pds);
MiningAttribute
,
MiningFunctionSettings
, Serialized FormConstructor Summary |
LogicalDataSpecification()
Creates an instance of LogicalDataSpecification with the specified array of
MiningAttribute s. |
Method Summary |
Type | Method |
---|---|
void |
addAttribute(MiningAttribute attribute)
Adds a mining attribute to the LDS. |
void |
adjustNonStringAttributesType(java.lang.String[] attrNames,
AttributeType changeToType)
Changes the attribute type of the spceified mining attributes in the LDS. |
static LogicalDataSpecification |
create(Connection dmsConn,
PhysicalDataSpecification pds)
Creates an instance of LogicalDataSpecification with the default settings
based on the database table specified in the input. |
static LogicalDataSpecification |
create(java.lang.String dbUrl,
java.lang.String userName,
java.lang.String password,
java.lang.String tableName,
java.lang.String schemaName,
PhysicalDataSpecification pds)
Deprecated. As of ODM 9.2.0. Use other create method. |
boolean |
equals(LogicalDataSpecification lds)
Checks the equality of two logical data specifications. |
MiningAttribute |
getMiningAttribute(java.lang.String name)
Returns a mining attribute with the specified name in the LDS. |
MiningAttribute[] |
getMiningAttributes()
Returns an array of mining attributes contained in the LDS. |
int |
getMiningAttributesCount()
Returns the total count of mining attributes contained in the LDS. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public LogicalDataSpecification()
LogicalDataSpecification
with the specified array of
MiningAttribute
s. A valid LogicalDataSpecification
object
must have mining attributes defined corresponding to the input mining data.Method Detail |
public MiningAttribute[] getMiningAttributes()
MiningAttribute[]
- An array of mining attributespublic MiningAttribute getMiningAttribute(java.lang.String name)
name
- An attribute nameMiningAttribute
- A mining attribute with the given namepublic void addAttribute(MiningAttribute attribute) throws InvalidArgumentException
The name of the mining attribute being added must be unique in the LDS.
Otherwise, the mining function settings object containing this LDS would become
invalid, which is checked when store
method in
MiningFunctionSettings
is invoked.
attribute
- An instance of mining attributeInvalidArgumentException
- MiningFunctionSettings
public boolean equals(LogicalDataSpecification lds)
lds
is null or does not have
the same mining attributes.lds
- An instance of LDS to be compared to this instanceboolean
- true if equal, false otherwiseMiningAttribute
public static LogicalDataSpecification create(java.lang.String dbUrl, java.lang.String userName, java.lang.String password, java.lang.String tableName, java.lang.String schemaName, PhysicalDataSpecification pds) throws InvalidArgumentException, java.sql.SQLException, ODMException
create
method.
LogicalDataSpecification
from the specified database table. This method supports both transactional
and non-transaction data.
Default settings of MiningAttribute
in the LDS are based
on the table column data type.
adjustNonStringAttributeType
method.dbUrl
- A JDBC URL like jdbc:oracle:thin:@host:port:siduserName
- A user namepassword
- The password of the specified user nametableName
- An input table name from which a logical data specification
is to be createdschemaName
- The schema name where the specified input table is locatedpds
- A physical data specification that describes the input tableLogicalDataSpecification
- An instance of logical data
specification createdInvalidArgumentException
- when an invalid argument is passedjava.sql.SQLException
- when there is a failure in JDBC callsAttributeUsage
,
create(
oracle.dmt.odm.Connection dmsConn,
PhysicalDataSpecification pds )
public static LogicalDataSpecification create(Connection dmsConn, PhysicalDataSpecification pds) throws InvalidArgumentException, java.sql.SQLException, ODMException
LogicalDataSpecification
with the default settings
based on the database table specified in the input.
Default settings of MiningAttribute
in the LDS are based on the table
column data type.
adjustNonStringAttributeType
method.dmsConn
- A connection to the data mining serverpds
- Input physical data specification used to create the associated
logical data specificationLogicalDataSpecification
- An instance of logical data
specification createdInvalidArgumentException
- dmsConn
or pds
is null, or
pds
does not contain a LocationAccessData
.
java.sql.SQLException
- when there is a failure in JDBC calls.LocationAccessData
, PhysicalDataSpecification
public void adjustNonStringAttributesType(java.lang.String[] attrNames, AttributeType changeToType) throws InvalidArgumentException
This method is especially useful when LDS is created using
the create
utility method. Scine create
method
uses the table column datatype as the basis for defining
attribute type, this method provides a convenient way
to modify the attribute types.
attrNames
- The names of mining attributes to be changedchangeToType
- New attribute typeInvalidArgumentException
- attrNames
or changeToType
is null, or
pds
does not contain a LocationAccessData
.
AttributeType
public int getMiningAttributesCount()
int
- The total count of mining attributes
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |