rainTotal as a generic #759
lordratner
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
weewx-belchertown/bin/user/belchertown.py
Line 3698 in a5268ef
Hey there
I created an extension recently for calculating chill hours. It looks at the temp during an interval, applies an algorithm, and calculates the chill hours for that interval. It's similar to how a rain is figured.
I bring this up because you have a function for rain that allows rainTotal to be displayed in a cumulative fashion. This is exactly how I'd like chill hours to be displayed. The only difference is that depending on the algorithm, chill hours can be negative, causing a decrease in the cumulative total over time. However I don't think that would change anything in the way your code calculates the rain total.
I plan to augment the code by duplicating the "if" statement for rainTotal and modifying it for chillTotal. But would it make more sense to instead change Belchertown to include the "cumulative" option (to supplement sum, max, min, avg) so that any future type that benefits from the cumulative/total aggregation could use it in charts or the main display? This could be used for metrics like Chill Hours, Growing Days, Solar Panel output, Evapotranspiration (already a WeeWX type), etc.
Thoughts?
Beta Was this translation helpful? Give feedback.
All reactions