File tree Expand file tree Collapse file tree 1 file changed +1
-2
lines changed
name.abuchen.portfolio.ui/src/name/abuchen/portfolio/ui/views/dashboard/heatmap Expand file tree Collapse file tree 1 file changed +1
-2
lines changed Original file line number Diff line number Diff line change @@ -109,7 +109,7 @@ DoubleFunction<Color> buildColorFunction(ResourceManager resourceManager)
109
109
// Transition between yellow and black
110
110
if (p > 0.6 )
111
111
{
112
- // 0.6 to 1.0 to 0 to 1.0
112
+ // 0.6 to 1.0 to ( 0 to 1.0 buchen's normalization)
113
113
float blackFactor = (float ) ((p - 0.6 ) / 0.4 );
114
114
color = Colors .interpolate (Colors .YELLOW .getRGB (), Colors .BLACK .getRGB (), blackFactor );
115
115
}
@@ -141,7 +141,6 @@ DoubleFunction<Color> buildColorFunction(ResourceManager resourceManager)
141
141
*/
142
142
private double normalizePerformance (double performance )
143
143
{
144
- // -0.05 + 0.07 / (2 * 0.07) = 0.02 / 0.14 = -0.14285714285714285
145
144
performance = Math .max (-MAX_PERFORMANCE , performance );
146
145
performance = Math .min (MAX_PERFORMANCE , performance );
147
146
return (performance + MAX_PERFORMANCE ) / (2 * MAX_PERFORMANCE );
You can’t perform that action at this time.
0 commit comments