Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Attend QlikWorld 2020 and hear keynote speaker, Malcolm Gladwell. Register by February 29th to save $200. Learn More
Highlighted
FabioP
New Contributor II

Problem in Sort a straight table after use ColorMix2 in background of an expression! ** With File **

Dearl all,

       I'm with a big problem (at least for me, rs*) where I need to use a heatmap with colors red, yellow and  green, in a table sorted from highest to lowest.
       The problem is, when I use the function 'top' inside the ColorMix2 the sort function is disable. So far so good, what I'm having trouble is finding a code that replaces this one:

ColorMix2 (if(rangemin(RangeMax (top(total Sum(Fator_FR),1,NoOfRows(total))),rangemax(Sum(Fator_FR),RangeMin (top(total Sum(Fator_FR),1,NoOfRows(total)))))<RangeAvg (top(total Sum(Fator_FR),1,NoOfRows(total))),(rangemin(RangeMax (top(total Sum(Fator_FR),1,NoOfRows(total))),rangemax(Sum(Fator_FR),RangeMin (top(total Sum(Fator_FR),1,NoOfRows(total)))))-RangeAvg (top(total Sum(Fator_FR),1,NoOfRows(total))))/(RangeAvg (top(total Sum(Fator_FR),1,NoOfRows(total)))-RangeMin (top(total Sum(Fator_FR),1,NoOfRows(total)))),(rangemin(RangeMax (top(total Sum(Fator_FR),1,NoOfRows(total))),rangemax(Sum(Fator_FR),RangeMin (top(total Sum(Fator_FR),1,NoOfRows(total)))))-RangeAvg (top(total Sum(Fator_FR),1,NoOfRows(total))))/(RangeMax (top(total Sum(Fator_FR),1,NoOfRows(total)))-RangeAvg (top(total Sum(Fator_FR),1,NoOfRows(total))))), ARGB(255, 0, 255, 0), ARGB(255, 255, 0, 0), ARGB(255, 255, 255, 0))

code.JPG

table.JPG


There is any other code that I can use  instead of this to get the same (or similar) heatmap result  and can sort the expression column from highest to lowest?


Thanks for everyone's help!

Labels (3)
1 Reply
Highlighted
FabioP
New Contributor II

Re: Problem in Sort a straight table after use ColorMix2 in background of an expression! ** With Fil

If it helps you to help me...
Follow my file: