Types of Data
Learn to identify and classify different types of data: categorical vs numerical, discrete vs continuous, and the four scales of measurement.
On This Page
Why Data Classification Matters
Before analyzing any dataset, you must understand what type of data you’re working with. The type of data determines:
- Which statistical methods are appropriate
- How to visualize the data effectively
- What summary statistics make sense
- Which hypothesis tests you can use
Using the wrong method for your data type can lead to meaningless or misleading results.
The Big Picture: Categorical vs Numerical
All data falls into two fundamental categories:
| Type | Description | Examples |
|---|---|---|
| Categorical | Data that represents groups or categories | Gender, color, yes/no responses |
| Numerical | Data that represents measurable quantities | Height, temperature, count of items |
Let’s explore each in detail.
Categorical (Qualitative) Data
Categorical data describes qualities or characteristics. It places observations into groups or categories.
Types of Categorical Data
1. Nominal Data
Categories with no natural order or ranking.
- Eye color: Blue, Brown, Green, Hazel
- Blood type: A, B, AB, O
- Country: USA, Canada, Mexico, Japan
- Marital status: Single, Married, Divorced, Widowed
- Pet type: Dog, Cat, Fish, Bird
Key characteristics:
- Categories are mutually exclusive
- No category is “greater” or “less” than another
- Can only count frequencies
- Mode is the only meaningful measure of central tendency
2. Ordinal Data
Categories with a meaningful order, but differences between categories aren’t equal.
- Education level: High School < Bachelor’s < Master’s < PhD
- Survey responses: Strongly Disagree < Disagree < Neutral < Agree < Strongly Agree
- Pain scale: None < Mild < Moderate < Severe
- Restaurant rating: ⭐ < ⭐⭐ < ⭐⭐⭐ < ⭐⭐⭐⭐ < ⭐⭐⭐⭐⭐
- Socioeconomic status: Low < Middle < High
Key characteristics:
- Categories have a logical order
- Distances between categories may not be equal
- Can use median and mode, but mean is problematic
- Can say “greater than” but not “how much greater”
Numerical (Quantitative) Data
Numerical data represents quantities that can be measured or counted. Mathematical operations are meaningful.
Types of Numerical Data
1. Discrete Data
Data that can only take specific, countable values. Usually integers (whole numbers).
- Number of children: 0, 1, 2, 3, … (can’t have 2.5 children)
- Number of cars owned: 0, 1, 2, 3, …
- Dice roll: 1, 2, 3, 4, 5, 6
- Number of customers: 0, 1, 2, 3, …
- Shoe size: 6, 6.5, 7, 7.5, … (finite set of values)
Key characteristics:
- Countable, finite values in any range
- Often integers, but not always
- Gaps exist between possible values
- “How many?” questions
2. Continuous Data
Data that can take any value within a range. Infinitely many possible values.
- Height: 165.2 cm, 165.23 cm, 165.234 cm, …
- Weight: Any value in a range (72.5 kg, 72.51 kg, …)
- Temperature: 98.6°F, 98.62°F, 98.623°F, …
- Time: 2.5 hours, 2.54 hours, 2.543 hours, …
- Blood pressure: 120.5 mmHg, 120.52 mmHg, …
Key characteristics:
- Infinitely many possible values between any two points
- Limited only by measurement precision
- No gaps between possible values
- “How much?” questions
The Four Scales of Measurement
Statistician Stanley Stevens proposed four levels of measurement, from least to most informative:
1. Nominal Scale
- Properties: Categories with no order
- Operations: Equality (=, ≠)
- Central tendency: Mode only
- Examples: Gender, nationality, eye color
2. Ordinal Scale
- Properties: Categories with order
- Operations: Equality and Order comparisons
- Central tendency: Mode, Median
- Examples: Rankings, education level, satisfaction ratings
3. Interval Scale
- Properties: Ordered with equal intervals, but no true zero
- Operations: Equality + Order + Addition/Subtraction
- Central tendency: Mode, Median, Mean
- Examples: Temperature (°C, °F), calendar years, IQ scores
- The difference between 20°C and 30°C is the same as 30°C to 40°C ✓
- But 0°C doesn’t mean “no temperature” (it’s just where water freezes)
- You can’t say “40°C is twice as hot as 20°C” ✗
4. Ratio Scale
- Properties: Ordered, equal intervals, AND a true zero point
- Operations: All mathematical operations
- Central tendency: Mode, Median, Mean, Geometric Mean
- Examples: Height, weight, age, income, distance
- Zero kg means “no weight” (true zero) ✓
- 100 kg is truly twice 50 kg ✓
- All mathematical operations make sense ✓
Comparison Chart
| Property | Nominal | Ordinal | Interval | Ratio |
|---|---|---|---|---|
| Categories | ✓ | ✓ | ✓ | ✓ |
| Meaningful order | ✗ | ✓ | ✓ | ✓ |
| Equal intervals | ✗ | ✗ | ✓ | ✓ |
| True zero | ✗ | ✗ | ✗ | ✓ |
| Example | Blood type | Pain level | Temperature (°C) | Height |
Identifying Data Types: Practice Framework
When classifying data, ask these questions in order:
1. Can you do arithmetic with it meaningfully?
├── NO → Categorical
│ ├── Is there a natural order?
│ │ ├── NO → Nominal
│ │ └── YES → Ordinal
└── YES → Numerical
├── Can it take any value in a range?
│ ├── NO → Discrete
│ └── YES → Continuous
└── Is there a true zero point?
├── NO → Interval
└── YES → Ratio
1. Number of siblings
- Numerical? Yes (arithmetic makes sense)
- Any value in range? No (0, 1, 2, 3…)
- True zero? Yes (0 means no siblings)
- Answer: Discrete, Ratio
2. Movie ratings (1-5 stars)
- Arithmetic meaningful? Debatable (ordinal)
- Natural order? Yes (5 > 4 > 3…)
- Answer: Ordinal
3. ZIP codes
- Arithmetic meaningful? No (90210 + 10001 = ?)
- Natural order? No (higher ≠ better)
- Answer: Nominal (even though they look like numbers!)
4. Reaction time (milliseconds)
- Numerical? Yes
- Any value? Yes (247.3 ms, 247.31 ms…)
- True zero? Yes (0 ms = instant)
- Answer: Continuous, Ratio
Common Pitfalls
1. Numbers Aren’t Always Numerical
Just because data contains digits doesn’t make it numerical:
- Phone numbers → Nominal
- ZIP codes → Nominal
- Jersey numbers → Nominal
- Social Security numbers → Nominal
2. Coded Categories
Sometimes categories are coded as numbers for convenience:
- Gender: 1 = Male, 2 = Female → Still Nominal
- Education: 1 = HS, 2 = Bachelor’s, 3 = Master’s → Still Ordinal
3. Discrete Can Look Continuous
Data with many discrete values (like income in dollars) can be treated as continuous for practical purposes.
4. Continuous Data is Always Recorded as Discrete
Due to measurement precision, we record continuous data with finite decimal places, but the underlying variable is still continuous.
Why This Matters for Analysis
| Data Type | Appropriate Visualizations | Summary Statistics | Common Tests |
|---|---|---|---|
| Nominal | Bar chart, Pie chart | Mode, Frequencies | Chi-square |
| Ordinal | Bar chart, Box plot | Median, IQR | Mann-Whitney, Wilcoxon |
| Interval/Ratio (Discrete) | Histogram, Bar chart | Mean, SD, Median | t-test, ANOVA |
| Interval/Ratio (Continuous) | Histogram, Box plot, Scatter plot | Mean, SD, Median | t-test, ANOVA, Regression |
Real-World Application
A clinical trial collects the following variables. Classify each:
| Variable | Classification | Reasoning |
|---|---|---|
| Patient ID | Nominal | Just an identifier |
| Age (years) | Ratio, Continuous | True zero, any value possible |
| Blood pressure (mmHg) | Ratio, Continuous | True zero, measurable |
| Pain level (0-10) | Ordinal | Ordered but intervals unequal |
| Treatment group (A, B, Placebo) | Nominal | No natural order |
| Number of adverse events | Ratio, Discrete | Countable, true zero |
| Tumor stage (I, II, III, IV) | Ordinal | Natural progression |
| Survived (Yes/No) | Nominal | Two unordered categories |
Summary
In this lesson, you learned:
- Categorical data represents groups (nominal = unordered, ordinal = ordered)
- Numerical data represents quantities (discrete = countable, continuous = measurable)
- The four scales of measurement: Nominal < Ordinal < Interval < Ratio
- True zero distinguishes interval from ratio scales
- Data type determines which statistical methods are appropriate
- Numbers aren’t always numerical—context matters!
Practice Problems
Classify each variable as Nominal, Ordinal, Discrete, or Continuous:
- Satisfaction score (Very Unsatisfied to Very Satisfied)
- Number of pets owned
- Hair color
- Body temperature in Fahrenheit
- Class rank (1st, 2nd, 3rd, …)
- Salary in dollars
- Favorite ice cream flavor
- Test score (0-100)
Click to see answers
- Ordinal - Ordered categories
- Discrete - Countable whole numbers
- Nominal - Unordered categories
- Continuous - Can take any value (but interval scale, not ratio)
- Ordinal - Ordered but differences aren’t equal
- Continuous - Can take any value (ratio scale)
- Nominal - Unordered categories
- Discrete - Finite set of values (could argue continuous if partial credit)
Next Steps
Now that you understand data types:
- Data Collection Methods - How to gather different types of data
- Measures of Central Tendency - Summarizing numerical data
- Data Visualization - Choosing the right charts for your data type
Was this lesson helpful?
Help us improve by sharing your feedback or spreading the word.