Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Long sensor names reveal a need to model how sensors are grouped within assets #442

Open
3 tasks
Flix6x opened this issue Jun 14, 2022 · 0 comments
Open
3 tasks

Comments

@Flix6x
Copy link
Contributor

Flix6x commented Jun 14, 2022

@ArdJonker suggested to move part of our y-axis label to the chart title, because the labels can be quite lengthy with respect to the chart height. For example:
image image

The y-axis label is currently made up of 2 components:

  • The sensor name, capitalized
  • The sensor unit, in parentheses

For example: Wind speed (m/s).

However, in practice, I've seen the sensor name used to contain more information than just the physical quantity, because we lack a data model to describe asset subgrouping. For example, I've seen Steam flow dryer 1 (t/h) and Nissan Leaf battery state of charge (%). In these cases, it would be preferable to use the sensor name only for holding the physical quantity (steam flow and state of charge, respectively), and moving the remainder (dryer 1 and Nissan Leaf battery, respectively) to some separate data model or attribute. When these characteristics are treated as separate data:

  • it will become more straightforward to show things like a single chart plotting steam flow over time for both dryer 1 and 2
  • y-axis labels will become shorter

I suggest:

  • increasing the default chart height for vertically concatenated charts
  • implementing a data model to hold sensor groupings within an asset, for example, a new asset attribute describing the sensor groupings, such as:
    {
        "house": {
            "solar panels": [4, 5],
            "other": [14],
            "charge point": {
                "EVSE 1": [16, 19, 33],
                "EVSE 2": [23, 63, 35],
                "EV 1": [83],
                "EV 2": [84],
                "EV 3": [85]
            },
            "energy contract": [1]
        }
    }
    
  • adding documentation explaining what should be considered a good sensor name to use in FlexMeasures:
    • good: wind speed
    • good: energy price
    • good: state of charge
    • bad: steam flow dryer 1 -> instead, create a sensor named steam flow and a sensor grouping named dryer 1
    • bad: day-ahead prices -> instead, create a sensor named energy price and a sensor grouping named day-ahead market
    • bad: Nissan Leaf battery power -> instead create a sensor named power output and a sensor grouping named Nissan Leaf battery
Flix6x added a commit that referenced this issue Jun 25, 2022
Introduce a collapsible sidepanel on the left of the sensor page, activated by hover or swipe, depending on the device. Also implements many smaller UX improvements:

- Show spinner while fetching new data
- Show single month and fewer custom ranges
- Rotate y-axis labels to improve legibility (addresses Issue #442)
- Update sensor data and annotations together instead of first come first serve
- Streamline calendar styling
- Streamline use of box shadows
- Fix positioning of chart actions button
- Move units to right side of tooltip
- Cancel previous request upon a new calendar selection
- Style navbar logo to have a consistent height and adjust the width of the navbar-header accordingly
- Actually load the font intended to be used in 0.10
- Make sure time axis labels aren't too close to each other


* Show updated sensor data and annotations together

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Show spinner while fetching new data

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Switch from id-based styling to class-based styling

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Move styling to css, and lower spinner

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Simplify and streamline datepicker fontsize

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Streamline datepicker margins

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Add margins and side panel activated on hover

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Correct margins and padding of side panel to allow for custom ranges at the bottom of the calendar

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Show single month

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Fewer custom ranges

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Side panel rounded similar to buttons rather than similar to cards

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Align box shadows of cards and calendar

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Non-transparent cards

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Simplified padding notation

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Move chart actions buttons away from the card's corner (negative margin)

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Rotate y-axis labels to improve legibility

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Remove sensor chart title if the same information is already contained in the y-axis label

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Move unit to right side of tooltip

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Style predefined datetime ranges

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Raise column to top without requiring flex display

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Rename sidepanel class and separate styling specific to the sidepanel being on the left

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Show spinner only while the promise is being fulfilled

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Cancel previous request when the user makes a new request

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Do not let spinner block the full page height, so the sensor table navigation can still be used

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Change header and label colors inside the sidepanel to contrast against the sidepanel background

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Style navbar logo to have a consistent height and adjust the width of the navbar-header accordingly

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Actually load intended font

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Enforce separation of time axis labels

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Add return type annotation and docs: applying chart defaults returns a dictionary with vega-lite specs

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Resolve hover glitch when exiting either the list of months or the list of years with the pointer. This stops the side panel from collapsing and reopening.

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Enable swiping for left sidepanel

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Stop using redundant litepicker plugin, which was messing with calendar styling

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Fix test

Signed-off-by: F.N. Claessen <felix@seita.nl>

* Changelog entry

Signed-off-by: F.N. Claessen <felix@seita.nl>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant