Page 1 of 1

Rain block

Posted: Fri Oct 20, 2017 10:27 pm
by giordolo
0 today is 0%, not 100% (see attach)
Cattura.PNG
Cattura.PNG (9.82 KiB) Viewed 8361 times

Re: Rain block

Posted: Fri Oct 20, 2017 10:29 pm
by Jachym
It is ok.

If in your database, rain for every Oct 20/21 is 0, it means that the highest rain ever on this day was 0mm. And 0 mm of 0mm is technically 100%.

Re: Rain block

Posted: Sat Oct 21, 2017 6:57 am
by giordolo
it is completely misleading to have a full circle for today when the rain is 0...... (and also, something divided by 0 is a math error, not 100).
Also note that the second circle is working fine: 0 this month, so 0. Why 0 today is 100?
is it possibile to have the absolute value without % comparison?

Re: Rain block

Posted: Sat Oct 21, 2017 7:33 am
by giordolo
Solved with a workaround: Show comparison to average period if available. = FALSE
Cattura.PNG
Cattura.PNG (9.19 KiB) Viewed 8340 times

Re: Rain block

Posted: Sat Oct 21, 2017 8:25 am
by Jachym
giordolo wrote: Sat Oct 21, 2017 7:33 am Solved with a workaround: Show comparison to average period if available. = FALSE
Cattura.PNG
It is not a workaround but an option in the settings :D

Re: Rain block

Posted: Sat Oct 21, 2017 9:13 am
by nikokara - BANNED
Hi giordolo

How do you see the persentage?

In my rain block i see this
rain_block.jpg
rain_block.jpg (14.76 KiB) Viewed 8327 times

Re: Rain block

Posted: Sat Oct 21, 2017 10:12 am
by giordolo
Jachym wrote: Sat Oct 21, 2017 8:25 am
giordolo wrote: Sat Oct 21, 2017 7:33 am Solved with a workaround: Show comparison to average period if available. = FALSE
Cattura.PNG
It is not a workaround but an option in the settings :D
ya you are right. It is still not comprehensible to me the why for the day 0 is 100% and for the month 0 is 0%

Re: Rain block

Posted: Sat Oct 21, 2017 10:14 am
by giordolo
nikokara wrote: Sat Oct 21, 2017 9:13 am Hi giordolo

How do you see the persentage?

In my rain block i see this

rain_block.jpg
http://www.pusterla.net/template/indexDesktop.php

Re: Rain block

Posted: Sat Oct 21, 2017 10:38 am
by nikokara - BANNED
ok i found why i see this.

if(count($averageRains)<364 || !$usePercentages)
if(count($averageRains)>=364 && $usePercentages)
:)