docs: @Override protected void initGraphics() {
          super.initGraphics();
  
          averagingListener = o -> handleEvents("AVERAGING");
  
          timeFormatter = DateTimeFormatter.ofPattern("HH:mm", tile.getLocale());
  
          if (tile.isAutoScale()) tile.calcAutoScale();
  
          niceScaleY = new NiceScale(tile.getMinValue(), tile.getMaxValue());
          niceScaleY.setMaxTicks(5);
          tickLineColor = Color.color(tile.getChartGridColor().getRed(), tile.getChartGridColor().getGreen(), tile.getChartGridColor().getBlue(), 0.5);
          horizontalTickLines = new ArrayList<>(5);
          tickLabelsY = new ArrayList<>(5);
          for (int i = 0 ; i < 5 ; i++) {
              Line hLine = new Line(0, 0, 0, 0);
              hLine.getStrokeDashArray().addAll(1.0, 2.0);
              hLine.setStroke(Color.TRANSPARENT);
              horizontalTickLines.add(hLine);
              Text tickLabelY = new Text("");
              tickLabelY.setFill(Color.TRANSPARENT);
              tickLabelsY.add(tickLabelY);
          }
  
          gradientLookup = new GradientLookup(tile.getGradientStops());
          low            = tile.getMaxValue();
          lastLow        = low;
          high           = tile.getMinValue();
          lastHigh       = high;
          stdDeviation   = 0;
          movingAverage  = tile.getMovingAverage();
          noOfDatapoints = tile.getAveragingPeriod();
          dataList       = new LinkedList<>();
  
          // To get smooth lines in the chart we need at least 4 values
          if (noOfDatapoints < 4) throw new IllegalArgumentException("Please increase the averaging period to a value larger than 3.");
  
          graphBounds = new Rectangle(PREFERRED_WIDTH * 0.05, PREFERRED_HEIGHT * 0.5, PREFERRED_WIDTH * 0.9, PREFERRED_HEIGHT * 0.45);
  
          titleText = new Text(tile.getTitle());
          titleText.setFill(tile.getTitleColor());
          Helper.enableNode(titleText, !tile.getTitle().isEmpty());
  
          valueText = new Text(String.format(locale, formatString, tile.getValue()));
          valueText.setFill(tile.getValueColor());
          Helper.enableNode(valueText, tile.isValueVisible());
  
          unitText = new Text(tile.getUnit());
          unitText.setFill(tile.getUnitColor());
          Helper.enableNode(unitText, !tile.getUnit().isEmpty());
  
          valueUnitFlow = new TextFlow(valueText, unitText);
          valueUnitFlow.setTextAlignment(TextAlignment.RIGHT);
  
          averageText = new Text(String.format(locale, formatString, tile.getAverage()));
          averageText.setFill(Tile.FOREGROUND);
          Helper.enableNode(averageText, tile.isAverageVisible());
  
          highText = new Text();
          highText.setTextOrigin(VPos.BOTTOM);
          highText.setFill(tile.getValueColor());
  
          lowText = new Text();
          lowText.setTextOrigin(VPos.TOP);
          lowText.setFill(tile.getValueColor());
  
          text = new Text(tile.getText());
          text.setTextOrigin(VPos.TOP);
          text.setFill(tile.getTextColor());
  
          timeSpanText = new Text("");
          timeSpanText.setTextOrigin(VPos.TOP);
          timeSpanText.setFill(tile.getTextColor());
          Helper.enableNode(timeSpanText, !tile.isTextVisible());
  
          stdDeviationArea = new Rectangle();
          Helper.enableNode(stdDeviationArea, tile.isAverageVisible());
  
          averageLine = new Line();
          averageLine.setStroke(Tile.FOREGROUND);
          averageLine.getStrokeDashArray().addAll(PREFERRED_WIDTH * 0.005, PREFERRED_WIDTH * 0.005);
          Helper.enableNode(averageLine, tile.isAverageVisible());
  
          pathElements = new ArrayList<>(noOfDatapoints);
          pathElements.add(0, new MoveTo());
          for (int i = 1 ; i < noOfDatapoints ; i++) { pathElements.add(i, new LineTo()); }
  
          sparkLine = new Path();
          sparkLine.getElements().addAll(pathElements);
          sparkLine.setFill(null);
          sparkLine.setStroke(tile.getBarColor());
          sparkLine.setStrokeWidth(PREFERRED_WIDTH * 0.0075);
          sparkLine.setStrokeLineCap(StrokeLineCap.ROUND);
          sparkLine.setStrokeLineJoin(StrokeLineJoin.ROUND);
  
          dot = new Circle();
          dot.setFill(tile.getBarColor());
  
          getPane().getChildren().addAll(titleText, valueUnitFlow, stdDeviationArea, averageLine, sparkLine, dot, averageText, highText, lowText, timeSpanText, text);
          getPane().getChildren().addAll(horizontalTickLines);
          getPane().getChildren().addAll(tickLabelsY);
      }