Rolling average for inTemp

65 views
Skip to first unread message

peterq...@gmail.com

unread,
Jan 2, 2021, 2:24:26 PM1/2/21
to weewx-user
Hi,

I'm trying to overlay a rolling average for inside temp. The heater going on and off introduces a cyclical pattern that I want to damp out. I'm following the example in the customization guide, except using inTemp and it doesn't appear to be working. I put the following in skin.conf:

      [[[dayinside]]]
            [[[[inTemp]]]]
            [[[[inTempAve]]]]
     color = 0x42b442 ##green
     data_type = inTemp
     aggregate_type = avg
     aggregate_interval = 1800
     label = Ave Temp

The title shows up in the right color but I don't get the average if I set the interval above about 600. Is there some limit for averages? I see the daily rain averages, so it looks like it should work. There are no error messages in the log, it just doesn't plot the average.

peterq...@gmail.com

unread,
Jan 2, 2021, 6:13:34 PM1/2/21
to weewx-user
FYI. This is what it looks like


p q

unread,
Jan 2, 2021, 6:15:27 PM1/2/21
to weewx...@googlegroups.com
image.png
I guess the Groups UI doesn't like embedded images

--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/d26604bb-9d9e-4c78-b480-15bb5419ac87n%40googlegroups.com.


--
Peter Quinn
(415)794-2264

Tom Keffer

unread,
Jan 2, 2021, 6:28:00 PM1/2/21
to weewx-user
You're getting bitten by "line gap fraction". This is an option that prevents lines from being drawn across big gaps in the data. The default is 0.01 (1%) of the x domain, or .27h, in this case. Your aggregation interval is 30 minutes, a bit more than the max allowable gap. Try this:

[[[dayinside]]]
  line_gap_fraction = 0.1

  [[[[inTemp]]]]
  [[[[inTempAve]]]]
     color = 0x42b442 ##green
     data_type = inTemp
     aggregate_type = avg
     aggregate_interval = 1800
     label = Ave Temp

p q

unread,
Jan 2, 2021, 7:51:20 PM1/2/21
to weewx...@googlegroups.com
Thanks! Works now. 

So I think the example in the customization guide won't work either. I can update it and put in a pull request if that helps the next guy.



--
Peter Quinn
(415)794-2264

Tom Keffer

unread,
Jan 2, 2021, 8:28:13 PM1/2/21
to weewx-user
The problem is that the value for line_gap_fraction is too low. It should be more like 0.05. 

Commit 94ae1e6.

That doesn't help existing users, but it does it make less likely that new users will trip up on it.

-tk

Reply all
Reply to author
Forward
0 new messages