Attribute values are numbers or symbols assigned to an attribute. The type of the attribute can be determined based on the assigned value.
The set of possible values - nominal, binary, ordinal, or numeric - the attribute can have.
Attributes | Possible Values |
hair_color | black, brown, red, green, and so on. |
marital_status | single, married, divorced, and widowed. |
occupation | teacher, doctor, farmer, student and so on. |
The nominal attribute values do not have any meaningful order about them and they are not quantitative. So
A binary attribute is a special nominal attribute with only two states: 0 or 1. Where 0 typically means that the attribute is absent, and 1 means that it is present.
A binary attribute is symmetric if both of its states are equally valuable and carry the same weight.
Example: the attribute gender having the states male and female.
A binary attribute is asymmetric if the outcomes of the states are not equally important.
Example: Test results for COVID patient: Positive (1) and Negative (0).
By convention, we code the most important outcome, which is usually the rarest one, by 1 (e.g., COVID positive) and the other by 0 (e.g., COVID negative).
An ordinal attribute is an attribute with possible values that have a meaningful order or ranking among them, but the magnitude between successive values is not known.
Example: An ordinal attribute drink_size corresponds to the size of drinks available at a fast-food restaurant.
Ordinal attributes are useful in surveys, In one survey, participants were asked to rate how satisfied they were as customers.
Customer satisfaction had the following ordinal categories:
0: very dissatisfied
1: somewhat dissatisfied
2: neutral
3: satisfied
4: very satisfied.
The central tendency of an ordinal attribute can be represented by its mode and its median (middle value in an ordered sequence), but the mean cannot be defined.
Interval-scaled attributes are measured on a scale of equal-size units. The values of interval-scaled attributes have order and can be positive, 0, or negative.We can compare and quantify the difference between values of interval attributes.
Examples:Although we can compute the difference between temperature values, we cannot talk of one temperature value as being a multiple of another.
Without a true zero, we cannot say, for instance, that 10oC is twice as warm as 5oC. That is, we cannot speak of the values in terms of ratios.
The central tendency of an interval attribute can be represented by its mode, its median (middle value in an ordered sequence), and its mean Data.
A ratio attribute is a numeric attribute with an inherent zero point.
Examples:- If a measurement is ratio scaled, we can speak of a value as being a multiple (or ratio) of another value.
The central tendency of an ratio attribute can be represented by its mode, its median (middle value in an ordered sequence), and its mean
Properties of Attribute ValuesThe type of an attribute depends on which of the following properties it possesses:
Nominal attribute: distinctness
Ordinal attribute: distinctness & order
Interval attribute: distinctness, order & addition
Ratio attribute: all 4 properties