You need $hour.outTemp.raw, not $hour.outTemp. The latter actually returns a "ValueHelper" object, which is ignorant of any comparison operators.
Incidentally, every tag $hour.outTemp involves a database lookup. You could be looking at 100 for each day. A simple speed up is to an intermediate, temporary variable: #set $hourTemp=$hour.outTemp.raw #if hourTemp >= 30 $set $VeryHotCount +=1 etc. On Thu, Apr 11, 2019 at 12:43 PM HoracioDos <[email protected]> wrote: > Hello > I'm writing my own stats template like NOAA text files. I defined a four > values temperature range and I want to count all hours in a month according > to its range. Final objetive is to create a monthly heatmap. > As aggregation types min/max_le/ge work with a day period or longer. I > made a cycle for the hours in each day for a month and evaluated the > temperature for each hour according to a range. There is a counter for each > range value that I want to report. > I can't make it work and I can't see $hour.outTemp value. What am I doing > wrong? I've attached the template and its output. > Thanks in advance > > -- > 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]. > For more options, visit https://groups.google.com/d/optout. > -- 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]. For more options, visit https://groups.google.com/d/optout.
