The types of variables in statistics that are commonly used are quantitative variables, qualitative variables, independent variables and dependent variables.
Any variables that can be expressed numerically are called quantitative variables. Some examples of quantitative variables are shown below.
Quantitative variables can either be discrete or continuous
The difference between a discrete variable and a continuous variable is straightforward.
If you can count something using only the numbers 1, 2, 3, 4, 5, ...., that thing is a discrete variable.
For example, how many cars do you own?
It is either you own 1, 2, 3, 4 and so forth. There is no such thing as owning 1 car plus 1/2 a car or 1.5 car.
How many children are in the classroom? There could be 25, 20, or 10 in the classroom. However, it will not make sense to say 20.5 children.
Based on this explanation, you can see that from the quantitative variables above, the discrete variables are the following.
A continuous variable though could have fractions and you cannot use only the numbers 1, 2, 3, 4, 5, 6, .... to find the variable.
For example, if I ask you for your age, you may answer, "I am 50 years old."
However, if I ask you the same question 6 months later, you will say 50 years and 6 months or 50.5 years old.
Since 6 months or 0.5 year is a fraction of 1 year, the variable is continuous.
Generally speaking, the word "count" does not apply to a continuous variable. You never hear people say, " count your height, " " count your weight, " etc.
They may instead say, " measure your height, " " measure your weight, " etc.
The word continuous probably came from the fact that the variable can continue to take on intermediate values between two consecutive whole numbers.
For example, between 2, and 3, there are lots of intermediate values such as 2.5, 2.33, 2.4447, 2.4, 2.00047, and millions of other intermediate values.
From the quantitative variables above, the discrete variables are the following.
A qualitative variable, also called categorical variable cannot be expressed with a numerical value. The variable can be observed. We cannot count it or measure it.
For example, the gender of college graduates is a qualitative variable.
Other examples of qualitative variables are shown below.
An independent variable can be manipulated so its values will change. A dependent variable cannot choose its values.
The value of the dependent variable will always depend on whatever values the independent variable takes on.
For example, income is an independent variable (a continuous independent variable) and number of cars purchased is a dependent variable (dependent discrete variable).
You can manipulate your income so it will change perhaps by working more, or less, or working hard to become a doctor or a CEO.
The number of cars you can own though will depend on your income.
As your income goes up, the number of cars you could own could also go up provided that you want to own more cars.