Open Dr-Hardware opened 6 years ago
Good catch! Here is a picture of the issue in the latest update with the issue underlined:
from #12753
Temperature units in the soil sampler results tooltip are currently displayed incorrectly in two different ways (also mentioned by @SlayksWood in #11063):
- As "0.00 C" under the "Plant" section, when below/above optimum or minimum/maximum, where the number appears to be a 0-1 range float to 2 decimal places, and
- As "0.0 degrees" under the "Land" section, where the number appears to be a 0-1 range float to 1 decimal place.
I believe both of these values are intended to be displayed as percentages.
It appears as though "Rainfall" is being used as the comparison layer for each plants IdealMoistureRange. Sagebrush has an IdealMoistureRange of 10% to 20%, however the following sample shows that the moisture of the measured location is 1% above the optimum (i.e., 21%), though the actual soil moisture is 17%:
Additionally, match comparisons seem to be made before rounding is applied, leading to fringe cases where plants would otherwise match for ideal conditions, but are reported as "0% above/below optimum" -- in this case, the IdealMoistureRange for Desert Moss is 20% to 25%, meaning a "Rainfall" (see above) of 20% should be a 100% match, however it reports as 98% match since the "Rainfall" is more likely to be 19.6% (i.e., 98% of 20%):
@SlayksWood @Quadbro Soil Sampler's InfoPanel now looks like this: @SlayksWood @WeaselDog does it need any tweaking?
Tested on 9.3 Staging-1952.
Soil Sample still needs an InfoPanel update. See the attached screenshot here:
In this screenshot, this is info taken using Soil Sampler on the Tomato plant. For temperature, it works by stating a percentage of match and optimal Celsius. By adding the Temperature Celsius of the Land and the indicated Below Optimum for the Plant, the Optimal Celsius Temperature for the Tomato is 18C. Now, I'm not certain how the Percentage Match is taken but the Match percentage doesn't make sense. Since, if the optimal celsius for Tomato is 18C and the Land temperature is, for example on one of the screenshots, 15.51C, then the match rate should be 15.51/18 = 86.1% Temperature Match(2.49 Celsius Below Optimal Level). So not sure how 79% is calculated.
It feels like the first percentage number under the plant section which is in the sentence "This location is a xx% match for the Tomatoes" copies the lowest number out of the four percentages under the plant section.
In this screenshot, the data shows 2 out of 4 percentages under the plant is not 100%.
So the match states "This location is a 48% match for this Amanita Mushroom". However, I'm not certain how 48% is calculated. Since it indicates "Match", I'm assuming that it should have been the average match percentage considering Pollution, Temperature, Rainfall, and Salt Water. So it should have been (63+75+100+100)/4 = 84.5% Match.
@Daniel-Magulado Just confirmed that the math for the Match is wrong, and that for the Temperature match it's correct.
Temperature match:
The 79% match for your Screenshot 1 is not 15.51 / 18
, but (15.51 - 6) / (18 - 6) = 0.7925
, with 6 being the minimum temperature that tomatoes can survive in.
Habitability Match:
In the codebase, the math for the habitability match is temperature% * rainfall% * pollution% * salt_water%
, where I also think it should indeed be (temperature% + rainfall% + pollution% + salt_water%) / 4
, as you said.
@Quadbro @johnkslg can you confirm about the Habitability match needing to follow the above formula?
As reported by a user at #21963,
Data shown by the soil sampler really has some issues. I tested the issues reported on the mentioned ticket and here is the screenshot comparison.
Observe the temperature reading for the match, optimum, and land. Soil sampler stated that the soil is 0.48 celsius below the minimum for the lands with 0.58 celsius reading, -7.68 celsius reading, and -7.53 celsius reading. On the 4th screenshot, it's 0% match at -7.95 which was a 0.27 bump on the temperature reading from -7.68. Yet, the soil sampler states 0% match with 4.67 celsius reading below optimum.
Data ends up being difficult to understand and this is important for the farmer specialty. Recommend to revisit how the Soil sampler computes data and show it. Make it much more friendly data information which does not use a complicated calculation as there is no explanation on how these data's are calculated.
Found a 99% temperature match for Tomatoes.
at 13.5 degrees it tells me its 0.01 degrees below optimum. why is the temperature 1 decimal place but the optimum 2 decimal places?