TapCub is live — analytics, insights and live chat, free on one platform
Glossary

What is discrete data? Examples and how it differs from continuous

Discrete data comes from counting and takes separate values, usually whole numbers. How to tell it from continuous data with web metric examples and a worked sessions-per-visitor distribution.

Su He Reviewed by Ethan Brooks Also called quantitative discrete data Last updated Nov 20, 2026 Glossary

Quick answer

Discrete data is quantitative data obtained by counting, which can take only separate, specific values, usually whole numbers, such as the number of orders, page views or items in a cart. It contrasts with continuous data, which is measured and can take any value in a range.

What is discrete data?

Discrete data is quantitative data that comes from counting and can take only separate, specific values, usually whole numbers. The number of orders, the number of pages viewed and the number of items in a cart are discrete: you can have 2 or 3, but not 2.4. OpenStax's introductory statistics text puts it this way: quantitative discrete data come from counting and take on only certain numerical values, such as the number of phone calls you receive each day being 0, 1, 2 or 3.

The phrase "quantitative discrete" simply combines two labels. Quantitative means the values are numbers you can add and average. Discrete says what kind of numbers: separate steps with gaps between them, not a smooth scale.

Discrete vs continuous data: how to tell them apart

Continuous data comes from measuring and can take any value in a range, including fractions and decimals. OpenStax's examples are lengths, weights and times, such as call lengths of 2.4, 7.5 or 11.0 minutes. Two questions settle most cases; the wider family of data kinds is covered in data types.

  1. Are you counting or measuring? Counting things gives discrete data. Measuring a quantity gives continuous data.
  2. Is a value between two neighbors meaningful? Between 3 and 4 page views there is nothing. Between 3 and 4 seconds there are infinitely many possible times.

Here is how common web and product metrics fall, with a note on how Google Analytics 4's reporting API types them. Its metric types include whole-number values (TYPE_INTEGER) and floating-point values for durations (TYPE_SECONDS, TYPE_MILLISECONDS), currency (TYPE_CURRENCY) and decimals (TYPE_FLOAT).

MetricDiscrete or continuous?WhyTypical type in a reporting API
Sessions per visitorDiscreteCounted: 1, 2, 3Integer
Page viewsDiscreteCountedInteger
Purchases or conversionsDiscreteCountedInteger
Items in a cartDiscreteCountedInteger
Session durationContinuousMeasured: 94.3 secondsSeconds (floating point)
Page load timeContinuousMeasuredMilliseconds (floating point)
Order valueContinuous in practiceAn amount, recorded to the centCurrency (floating point)
Scroll depthContinuousA measured percentageFloat
Conversion rateContinuousA ratio of two counts, any value from 0 to 1Float
Star rating 1 to 5Discrete (ordinal)Separate steps, but the gaps may not be equalInteger

Two clarifications avoid the common confusions. Counts of different things can still divide into continuous results: a conversion rate is built from two discrete counts, but 63 ÷ 420 = 0.15 is a ratio and can be any value. And a number is not always quantitative: a phone number or an order ID is made of digits but you would never add or average them, so it is an identifier, not discrete data.

Worked example: sessions per visitor

Sample data: the number of sessions in the last 30 days for 20 sample visitors: eight visited once, four twice, three three times, and one each at 4, 5, 6, 8 and 13.

Sessions in 30 daysVisitorsShare of visitors
1840%
2420%
3315%
415%
515%
615%
815%
1315%
Total20100%

The totals are 8 + 8 + 9 + 4 + 5 + 6 + 8 + 13 = 61 sessions across 20 visitors. The summary values are:

  • Mean = 61 ÷ 20 = 3.05 sessions per visitor. A discrete variable can have a mean that is not a whole number; no visitor had 3.05 sessions, and that is fine, because the mean describes the group.
  • Median = 2, the average of the 10th and 11th sorted values, both 2.
  • Mode = 1, the most common value (8 of 20 visitors).

Notice how different the three numbers are. The mean of 3.05 sits above the median of 2 because a few heavy users pull it up: the four visitors with 5 or more sessions are 20% of visitors but 5 + 6 + 8 + 13 = 32 of the 61 sessions, 52.5%. Reporting only "3.05 sessions per visitor" would suggest a typical visitor comes back three times, when 40% came exactly once.

A continuous counterpart makes the contrast clear. Take session durations in seconds for 10 sample sessions: 12.4, 35.0, 48.2, 61.7, 95.3, 120.0, 150.5, 203.9, 310.2, 420.8. The mean is 145.8 and the median 107.65. Nobody would draw this as a bar per value, because no two sessions are likely to share one; you group it into ranges first.

How to summarize and chart discrete data

Discrete data has natural groups, so use them.

TaskUseReason
Show the shapeFrequency table or bar chart with one bar per valueEach value is a separate category with a gap between bars
Summarize a typical valueMedian and mode, with the mean beside themCounts are often skewed; one heavy user moves the mean
Compare groupsShare of people at each value, or a rate per 100 visitorsTotals are misleading when group sizes differ
Handle a long tailGroup into 1, 2, 3, 4 to 5 and 6 or moreKeeps the chart readable without hiding the shape

Continuous data is usually grouped into ranges and shown as a histogram, where the bars touch because the scale is unbroken. A practical rule: bars with gaps for counts, touching bars for measurements.

Common mistakes with discrete data

  • Reading the mean as a typical case. In the example the mean (3.05) describes nobody; 2 or 1 does. Show the distribution.
  • Treating an averaged count as a count. Pages per session averaged to 2.7 is a mean of counts, not a count.
  • Forgetting measurement resolution. Duration is continuous in nature, but a tool that records whole seconds stores it in discrete steps. That matters little at 94 seconds and a lot at 0 or 1 second, where rounding changes the picture.
  • Calling every number discrete. Revenue, load time and scroll depth are measured, not counted.
  • Using a type that breaks the math. If an amount is stored as text, sums and filters fail; check the data type of every property before you build a report on it.

Looking at discrete data in TapCub

TapCub's distribution model is built for exactly this view: how a count is spread across people.

  1. Open the chart. In All-platform analytics › Behavior › Behavior analysis, choose the Distribution model and pick the subject: how many times each person fired an event, active days, a numeric property, pages per session or session duration.
  2. Read the buckets. For event counts and pages per session, TapCub uses widening edges such as 1, 2, 3, 5, 10 (about 12 buckets) unless you type your own, up to 50. Active days get one bucket per day when the range is 31 days or less. The histogram shows each bucket's count and share, plus the mean and median, so you can see both numbers from the example side by side.
  3. Treat measurements differently. A numeric property is split into equal-width bins from the minimum to the 99th percentile (2 to 50 bins, default 10). Session duration uses fixed duration edges.
  4. Check the type. In All-platform analytics › Data › Property dictionary each property has a type (String, Number, Boolean, Datetime or List). A wrong type breaks sums and filters, so confirm that amounts and counts are Number before you chart them.
  5. Build a count per person. In All-platform analytics › Behavior › Metrics & SQL you can define a metric as an event plus an aggregation, such as total count, distinct people or per person, and also property sum, average, median or P90.

Sources

Was this explanation clear?

We use your answers to fix and expand this page.

Su He

Data Analyst

Explores traffic sources, conversion funnels, and retention, using clear metric definitions and concrete examples to explain what the numbers mean.

FAQ

Questions people ask

Short answers to the follow-up questions that come up most.

Still have a question?

Chat with the team behind TapCub — we usually reply within a few hours on business days.

What is an example of discrete data?

The number of orders a customer placed, the pages viewed in a session or the items in a cart. Each is counted and can be 2 or 3 but never 2.4.

What is the difference between discrete and continuous data?

Discrete data is counted and takes separate values. Continuous data is measured and can take any value in a range, including decimals, such as session duration or load time.

Can the average of discrete data be a decimal?

Yes. A mean of 3.05 sessions per visitor is fine even though no visitor has 3.05 sessions, because the mean describes the group. Show the median and the distribution beside it.

Is conversion rate discrete data?

No. Conversions and visitors are each counted, but a conversion rate such as 63 ÷ 420 = 0.15 is a ratio that can take any value between 0 and 1, so it is treated as continuous.

See this number on your own site

Add one script tag for web and apps, and the first reports fill in within minutes.

See your data clearly. Find your growth.

Every click, backed by data. Install one line of code and see your first numbers in a minute.

No credit card · Free plans for analytics and chat · Cookieless analytics