This view contains historical occupancy data per location, aggregated in 15-minute time slots.
These timeslots contain occupancy values per monitored location, based on the raw sensor data values but without the complexity of understanding raw sensor data.
Data structure
Column | Meaning | Comment |
|---|---|---|
Unique primary key | Is a concatenation of location_id + Calendar_datetime | |
calendar_date | Calendar date in ISO 8601 format | e.g. 2025-10-28 |
day_of_week | Integer value between 1 (Monday) and 7 (Sunday) | Also for US |
calendar_datetime | Date + Time that represents the timeslot in local time In ISO 8601 format | e.g. 2025-10-28T08:00:00 2025-10-28T08:15:00 2025-10-28T08:30:00 2025-10-28T08:45:00 |
timeslot_start | Same information as calendar_datetime but as a STRING and including time zone. | e.g. |
hour_of_day | Integer value between 0 (1st hour) to 23 (last hour) | |
creation_datetime | Technical timestamp when the row was created, in ISO 8601 format and always in UTC | |
location_id | Unique key of the location | see locations_v1 |
location_class | Class of location | Built in enum: |
parent_location_id | Unique key of the parent location | see locations_v1 |
parent_location_class | Class of parent location | Built in enum: |
building_id | Unique key of building | see locations_v1 |
floor_id | Unique key of floor | see locations_v1 |
space_class | Space Class | Built in enum: |
Capacity of the location | Value depends on location_class: For FLOOR: sum of capacities of sublocations | |
locations_total | Nr of sublocations | Regardless if they are monitored or not |
Nr of sublocations with occupancy sensor | Used for occupancy rate calculations | |
locations_occupied | Nr of sublocations that are occupied during the timeslot | Used for occupancy rate calculations |
rooms_total | Nr of rooms in total, including the ones that are not monitored | Only useful for location_class = FLOOR |
Nr of rooms with occupancy sensor | Only useful for location_class = FLOOR | |
workplaces_total | Nr of workplaces in total, including the ones that are not monitored | Only useful for location_class = FLOOR |
Nr of workplaces with occupancy sensor | Only useful for location_class = FLOOR | |
Data class of occupancy sensor | Built-in enum: | |
Monitored value in the timeslot | Is always 1 (occupied) or 0 (not occupied) per timeslot | |
headcount_peak | Highest headcountregistered during the timeslot | Sensors measure values at irregular intervals. Spacewell calculates the highest, lowest and average values per 15-minute timeslot |
headcount_low | Lowest headcount registered during the timeslot | |
headcount_average | Average headcount registered during the timeslot | |
Nr of hours that the space was occupied in the timeslot | For 15-minute timeslot, values are between 0 and 0,25h | |
Nr of hours that the space was occupied in the timeslot, divided by 0,25h | The percentage is rounded to 2 decimals | |
Average headcount divided by capacity | The percentage is rounded to 2 decimals | |
locations_occupied divided by locations_occupancy_monitored | The percentage is rounded to 2 decimals . | |
business_day_start_hour | Start of business day (time value) | Derived from Studio |
business_day_end_hour | End of business day (time value) | Derived from Studio |
|
Calculations
Values are recorded 24 hours per day, all 365 days of the year.
The business_day_start_hour and business_day_end_hour are recorded for historical purposes.
All values are historical!
They are calculated at the time of recording and may not represent the current values.
This is especially important to understand for capacity, space category, locations_total etc.
Example:
For each monitored space, the table contains values for presence and headcount every quarter-hour.
If the space is using a headcount sensor, then
- The headcount values are stored as follows:
Headcount_peak = highest headcount recorded during the quarter-hour
- Headcount_low = lowest headcount recorded during the quarter-hour
- Headcount_average = average headcount during the quarter-hour
- The presence value is simply derived from the headcount:
If headcount_average > 0 then presence = 1 else presence = 0
If the space is using a presence sensor, then
- The presence value is recorded via the sensor:
If the sensor detects presence at least once during the quarter-hour then presence = 1 else presence = 0
- The headcount values are calculated as follows:
If presence = 1 then headcount_peak = 1, headcount_low = 1, headcount_average = 1
- If presence = 0 then all headcount values are 0
All the other metrics are calculated based on the presence, headcount and capacity of the space (see table above).