hass.tibber_prices/custom_components/tibber_prices/sensor/calculators
Julian Pawlowski abb02083a7 feat(sensors): always show both mean and median in average sensor attributes
Implemented configurable display format (mean/median/both) while always
calculating and exposing both price_mean and price_median attributes.

Core changes:
- utils/average.py: Refactored calculate_mean_median() to always return both
  values, added comprehensive None handling (117 lines changed)
- sensor/attributes/helpers.py: Always include both attributes regardless of
  user display preference (41 lines)
- sensor/core.py: Dynamic _unrecorded_attributes based on display setting
  (55 lines), extracted helper methods to reduce complexity
- Updated all calculators (rolling_hour, trend, volatility, window_24h) to
  use new always-both approach

Impact: Users can switch display format in UI without losing historical data.
Automation authors always have access to both statistical measures.
2025-12-18 15:12:30 +00:00
..
__init__.py feat(sensor): add data lifecycle diagnostic sensor with push updates 2025-11-20 15:12:41 +00:00
base.py refactor(price_info): price data handling to use unified interval retrieval 2025-11-24 10:49:34 +00:00
daily_stat.py refactor(currency)!: rename major/minor to base/subunit currency terminology 2025-12-11 08:26:30 +00:00
interval.py refactor(currency)!: rename major/minor to base/subunit currency terminology 2025-12-11 08:26:30 +00:00
lifecycle.py refactor: simplify needs_tomorrow_data() - remove tomorrow_date parameter 2025-11-24 16:26:08 +00:00
metadata.py refactor(naming): complete class naming convention alignment 2025-11-20 11:22:53 +00:00
rolling_hour.py feat(sensors): always show both mean and median in average sensor attributes 2025-12-18 15:12:30 +00:00
timing.py refactor: migrate from multi-home to single-home-per-coordinator architecture 2025-11-24 16:24:37 +00:00
trend.py feat(sensors): always show both mean and median in average sensor attributes 2025-12-18 15:12:30 +00:00
volatility.py feat(sensors): always show both mean and median in average sensor attributes 2025-12-18 15:12:30 +00:00
window_24h.py feat(sensors): always show both mean and median in average sensor attributes 2025-12-18 15:12:30 +00:00