In: Statistics and Probability
Define what categorical and continuous variables are
and provide several examples of each.
Categorical variable:
Categorical variables contain a finite number of categories or distinct groups. Examples of categorical variables are race, sex, age group, educational level. Hence it is often said that categorical variables can only take one of a limited number of values As in our examples, the variable sex can take the categories like "male", "female" or "third gender". Again educational level can take values or classes like "up to class 10", "up to class 12", "BSc. graduate " "MSc" "PhD" etc .Categorical data might not have a logical order for example when our variable is Religion, then all its possible values are "Hindu", "Muslim", "Christian" etc but we can not say "Hindu " has a higher value than "Muslim" or vice versa. Similarly when we are talking about eye colour "black" can not be in a higher position than "brown".
Continuous variable:
Continuous variables can take on almost any numeric value within its range of variation and can be meaningfully divided into smaller increments, including fractional and decimal values. For example, when you measure height, weight, temperature etc you have continuous data. By saying a Conti variable takes any value within its range of variation I mean that not every continuous variable will take any value on real line but may take infinite values within a certain part of the real line. For example when we consider the weight of an adult human than the range of variation more or less lies between 5Kg to 300Kg. Notice that the weight can not take negative values on the real line also it can not take very high values but it can take any value in between the range provided. Also, it can take any fractional or decimal value in between so there are infinitely many possible values for the variable weight. Here the next thing we observe that values have a clear ordering. Like 53Kg is greater than 52Kg and less than 53.5Kg. So it can be divided into smaller increments,