oracle.dmt.odm.data
Class MiningAttribute

java.lang.Object
  |
  +--oracle.dmt.odm.MiningObject
        |
        +--oracle.dmt.odm.data.Attribute
              |
              +--oracle.dmt.odm.data.MiningAttribute
All Implemented Interfaces:
java.io.Serializable

public class MiningAttribute
extends Attribute

An instance of MiningAttribute is a logical concept that describes a domain of data to be used as input to data mining operations. Mining attributes are typically either categorical or numerical. Each mining attribute must have a unique name with a given LogicalDataSpecification instance.

Since:
9.0.1
See Also:
Serialized Form

Constructor Summary
MiningAttribute(java.lang.String name, DataType dataType, AttributeType attributeType)
          Creates a new MiningAttribute instance.
MiningAttribute(java.lang.String name, DataType dataType, AttributeType attributeType, boolean isParentGroup, boolean isKey)
          Deprecated. As of 9.2.0.
 
Method Summary
TypeMethod
 void addNestedAttribute(MiningAttribute attribute)
          Deprecated. As of ODM 9.2.0, nested attribute is not supported.
 boolean equals(MiningAttribute attribute)
          Checks the equality of this attribute against the specified attribute.
 AttributeType getAttributeType()
          Returns the type of this attribute.
 boolean getIsKey()
          Deprecated. As of ODM 9.2.0, use supplemental of AttributeUsage.
 boolean getIsParentGroup()
          Deprecated. As of ODM 9.2.0, nested attribute is not supported.
 MiningAttribute getNestedAttribute(java.lang.String attributeName)
          Deprecated. As of ODM 9.2.0, nested attribute is not supported.
 MiningAttribute[] getNestedAttributes()
          Deprecated. As of ODM 9.2.0, nested attribute is not supported.
 int getValueCount()
          Deprecated. As of ODM 9.2.0, distinct values are not counted.
 boolean isNested()
          Deprecated. As of ODM 9.2.0, nested attribute is not supported.
 void setAttributeType(AttributeType attributeType)
          Sets the attribute type.
 void setIsKey(boolean key)
          Deprecated. As of ODM 9.2.0, use supplemental of AttributeUsage.
 void setIsParentGroup(boolean value)
          Deprecated. As of ODM 9.2.0, nested attribute is not supported.
 void setValueCount(int count)
          Deprecated. As of ODM 9.2.0, distinct values are not counted.
 
Methods inherited from class oracle.dmt.odm.data.Attribute
equals, getDataType, getName, setDataType
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MiningAttribute

public MiningAttribute(java.lang.String name,
                       DataType dataType,
                       AttributeType attributeType)
                throws InvalidArgumentException,
                       ODMException
Creates a new MiningAttribute instance.
Parameters:
name - The name of the attribute
dataType - The data type of the attribute (e.g., int)
attributeType - The type of the attribute (e.g., categorical)
Throws:
InvalidArgumentException -
  • when name, dataType, or attributeType is null, or
  • when name is null, empty or exceeds 30 bytes in length.
Since:
9.2.0

MiningAttribute

public MiningAttribute(java.lang.String name,
                       DataType dataType,
                       AttributeType attributeType,
                       boolean isParentGroup,
                       boolean isKey)
                throws InvalidArgumentException,
                       ODMException
Deprecated. As of 9.2.0.

Creates a new MiningAttribute instance.
Parameters:
name - The name of the attribute
dataType - The data type of the attribute (e.g., int)
attributeType - The type of the attribute (e.g., categorical)
isParentGroup - true if parent attribute, false otherwise
isKey - true if primary key, false otherwise
Throws:
InvalidArgumentException -
  • when name, dataType, or attributeType is null, or
  • when name is null, empty or exceeds 30 bytes in length.
Method Detail

getValueCount

public int getValueCount()
Deprecated. As of ODM 9.2.0, distinct values are not counted.

Returns the number of distinct values in this attribute
Returns:
int - The number of distinct values

getAttributeType

public AttributeType getAttributeType()
Returns the type of this attribute.
Returns:
AttributeType - The type of this attribute
See Also:
AttributeType

getIsKey

public boolean getIsKey()
Deprecated. As of ODM 9.2.0, use supplemental of AttributeUsage.

Returns true if the attribute is a key.
Returns:
boolean - true if a key, false otherwise
See Also:
AttributeUsage

setIsKey

public void setIsKey(boolean key)
Deprecated. As of ODM 9.2.0, use supplemental of AttributeUsage.

Changes the keyness of the attribute as specified. The attribute becomes a key if true, or a non-key attribute if false.
Parameters:
key - The keyness of the attribute
See Also:
AttributeUsage

setValueCount

public void setValueCount(int count)
Deprecated. As of ODM 9.2.0, distinct values are not counted.

Sets the number of distinct values in this attribute. param count The number of distinct values

addNestedAttribute

public void addNestedAttribute(MiningAttribute attribute)
                        throws InvalidArgumentException
Deprecated. As of ODM 9.2.0, nested attribute is not supported.

Adds the specified attribute as a nested attribute of this attribute.
Parameters:
attribute - - A mining attribute to be added
Throws:
InvalidArgumentException -
  • when attribute is null, or
  • when attribute is already nested.

getNestedAttributes

public MiningAttribute[] getNestedAttributes()
Deprecated. As of ODM 9.2.0, nested attribute is not supported.

Returns an array of nested attributes in this attribute.
Returns:
MiningAttribute[] - An array of nested attributes

getNestedAttribute

public MiningAttribute getNestedAttribute(java.lang.String attributeName)
Deprecated. As of ODM 9.2.0, nested attribute is not supported.

Returns the nested attribute with the specified name. Returns null if not found.
Parameters:
attributeName - An attribute name
Returns:
MiningAttribute - The mining attribute with the specified name

setIsParentGroup

public void setIsParentGroup(boolean value)
                      throws InvalidArgumentException
Deprecated. As of ODM 9.2.0, nested attribute is not supported.

Changes the parenthood of the attribute. The attribute becomes a parent attribute if value is true.
Parameters:
value - An indicator for parenthood
Throws:
InvalidArgumentException - when the attribute has nested attributes and value is false.

getIsParentGroup

public boolean getIsParentGroup()
Deprecated. As of ODM 9.2.0, nested attribute is not supported.

Returns the parenthood of the attribute.
Returns:
boolean - true if parent attribute, false otherwise

isNested

public boolean isNested()
Deprecated. As of ODM 9.2.0, nested attribute is not supported.

Returns a flag whether the attribute is nested.
Returns:
boolean - true if nested, false otherwise

equals

public boolean equals(MiningAttribute attribute)
Checks the equality of this attribute against the specified attribute. Two mining attributes are equal if they have the same name, data type, and attribute type.
Parameters:
attribute - An attribute to be compared
Returns:
boolean - true if equal, false otherwise

setAttributeType

public void setAttributeType(AttributeType attributeType)
Sets the attribute type.
Parameters:
attributeType - attribute type
See Also:
AttributeType