I extended the weewx-GTS extension <https://github.com/roe-dl/weewx-GTS>.

This also refers to the issue #91 <https://github.com/weewx/weewx/issues/91> 
and 
the discussion Australia New Weather Measurement Day is 9am not Midnight 
<https://groups.google.com/g/weewx-user/c/kcblP3PUwU8> here at Google. But 
at first I considered that the plants know nothing about timezones and 
daylight saving time. On the other hand, local timezones can easily be 2 or 
even 3 hours away from local sundial time. That is much. And calculating 
averages or max and min values with a day boundary that much away from real 
midnight (antitransit of the sun) may not be optimal.

So I created some additional tags to define time spans that have other day 
boundaries than midnight local timezone time. The offset ist defined within 
the tag. For example, if you want to aggregate from 9:00 am to 9:00 am and 
your local timezone offset is 2:00, you could write

$offsetday(dayboundary=-25200).rain.sum

to get the rain of the day with day boundary at 9:00 am. Please note: The 
offset is in seconds from UTC. For Python <3.7 the value is rounded to 
whole minutes.

$offsetmonth() and $offsetyear() are also available.

$LMTday, $LMTmonth, $LMTyear define the day according to Local Mean Time, 
which is at most a quarter of an hour away from sundial time and thus may 
be the best base to calculate growing degree days.

It is still beta.

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/8e50b859-29ae-4cbe-8120-556b3d5b80a9n%40googlegroups.com.

Reply via email to