Skip to content

Cookie preferences

We use cookies for our own analytics, to see how our campaigns perform and, if you allow it, to load content from other services such as the Google site search. We never sell your data. Necessary cookies keep the site working and cannot be switched off. See our Cookie Policy for details and our Privacy Policy for how we handle personal data.

Security, load balancing and remembering your cookie choice.

Show us which pages people read and how they find the site, so we can improve it (Google Analytics).

Show us which of our ad campaigns bring visitors to the site and remember the campaign or partner link you arrived from (Google Ads, partner program). We do not use these cookies to build advertising profiles.

Load the site search from Google when you use it. Google sets its own cookies and shows ads in the search results.

© 2026 The ThingsBoard Authors
22.5k Try for free

ThingsBoard Cloud

Choose your data region

Your data stays in the region you choose, for residency and compliance. No credit card required.

Rather run it yourself? Install on your own servers

Grouping by Time

To show how data changes over time, put the Date field on the X-axis of a view. Trendz splits the time range of the date picker into intervals, called buckets, and reduces the data in each bucket to one value. A bucket without data is shown as -.

Each bucket covers one interval of the range. The field on the Y-axis is aggregated inside it, for example summed. A smaller bucket gives more points and more detail.

The Date field has two kinds of grouping:

Grouping Bucket size is set by Use it for
RAW The group by control, at any time Trends you zoom in and out of
Fixed option The view configuration Patterns, like the typical day or week

RAW is the default Date aggregation. The group by control next to the date picker sets the bucket size, and anyone who opens the view can change it.

Unit One bucket per
minute Minute
hour Hour
day Calendar day
week Calendar week, starting on Monday
month Calendar month
quarter Calendar quarter
year Calendar year

Group by amount merges several units into one bucket, like every 6 hours or every 3 days. It works in RAW mode only.

  1. Open the view settings and select Group by amount in the General section.

  2. An amount field appears in the group by control, before the unit. Enter the number of units per bucket.

  3. Click Build report.

A fixed option groups by a part of the date, like the hour of the day or the day of the week, and ignores the rest. Readings from every day in the range with the same hour land in the same bucket, so the chart shows a pattern whatever the range.

  1. Click the Date field on the X-axis.

  2. In Aggregation, select an option instead of RAW.

  3. Click Build report.

With a fixed option the group by control is hidden.

Option Groups data by Example label
MINUTE Minute of the hour (0–59) 45
HOUR Hour of the day (0–23) 23
DAY Day of the week (Mon–Sun) Monday
DATE Day of the month (1–31) 15
FULL_MINUTE Exact date and minute 2026-03-01 23:45
FULL_HOUR Exact date and hour 2026-03-01 23
FULL_DATE Exact calendar date 2026-03-01
FULL_QUARTER Year and quarter 2026-Q1
START_OF_WEEK Monday of the calendar week 2026-03-02
WEEK_OF_YEAR Week of the year (W1–W54) W10
WEEK_OF_MONTH Week of the month (1–6) 2
MONTH Month of the year (Jan–Dec) March
YEARMONTH Year and month 2026-Feb
QUARTER Quarter of the year (1–4) 1
YEAR Calendar year 2026

The FULL_ options, START_OF_WEEK, YEARMONTH, and YEAR keep the date, so they give a timeline with a fixed bucket size. The others fold the range into a pattern.

Day and week boundaries follow the time zone of the date picker. START_OF_WEEK and WEEK_OF_YEAR label a bucket by its week even when Monday is outside the range; only data inside the range is counted.

Choose When
RAW The view is used with different ranges, and viewers change the detail with group by
Fixed option You want a pattern, like average energy per hour of the day or per day of the week