Attribute type.
Attribute type.
Get the number of values, either from numValues
or from values
.
Get the number of values, either from numValues
or from values
.
Return None if unknown.
Gets a value given its index.
Tests whether this attribute contains a specific value.
optional index
optional index
Index of a specific value.
Tests whether this attribute is nominal, true for NominalAttribute and BinaryAttribute.
Tests whether this attribute is nominal, true for NominalAttribute and BinaryAttribute.
Tests whether this attribute is numeric, true for NumericAttribute and BinaryAttribute.
Tests whether this attribute is numeric, true for NumericAttribute and BinaryAttribute.
whether this attribute is ordinal (optional)
optional name
optional name
optional number of values.
optional number of values. At most one of numValues
and values
can be
defined.
Converts to ML metadata
Converts to ML metadata
Converts to ML metadata with some existing metadata.
Converts to ML metadata with some existing metadata.
Converts to a StructField.
Converts to a StructField.
Converts to a StructField with some existing metadata.
Converts to a StructField with some existing metadata.
existing metadata to carry over
optional values.
optional values. At most one of numValues
and values
can be defined.
Copy with a new index.
Copy with a new index.
Copy with a new name.
Copy with a new name.
Copy with a new numValues
and empty values
.
Copy with new values and empty numValues
.
Copy with new values and empty numValues
.
Copy with new values and empty numValues
.
Copy without the index.
Copy without the index.
Copy without the name.
Copy without the name.
Copy without the numValues
.
Copy without the values.
:: DeveloperApi :: A nominal attribute.