Skip to main content
Announcements
Do More with Qlik - Qlik Cloud Analytics Recap and Getting Started, June 19: REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Including dimension

Hi All,

We have a straight table where we are getting color values using colormix formula.

But when we select any one dimension, we want the actual color value of the color expression should be available. when we try to ignore the dimension in the expression, even if we select the dimension, unwanted records are coming.

Any idea on same.

Please assist.

Regards,

MK

1 Solution

Accepted Solutions
sunny_talwar

I attached the application. Used this expression:

If(sum(Vol) > 0,

ColorMix1 ((1+Sign(2*(sum({<state=>}Vol)-RangeMin (top(total sum({<state=>}Vol),1,NoOfRows(total))))/(RangeMax (top(total sum({<state=>}Vol),1,NoOfRows(total)))-RangeMin (top(total sum({<state=>}Vol),1,NoOfRows(total))))-1)*Sqrt(Fabs((2*(sum({<state=>}Vol)-RangeMin (top(total sum({<state=>}Vol),1,NoOfRows(total))))/(RangeMax (top(total sum({<state=>}Vol),1,NoOfRows(total)))-RangeMin (top(total sum({<state=>}Vol),1,NoOfRows(total))))-1))))/2, ARGB(255, 255, 0, 0), ARGB(255, 0, 255, 0)))

As soon as you make a selection in State Sum(Vol) becomes 0 and all other rows for colormix become null

HTH

Best,

Sunny

View solution in original post

8 Replies
sunny_talwar

Would you be able to share the application or a sample may be?

Anonymous
Not applicable
Author

Hi,

PFA where there are two straight table in the application.

Now when i select A from state filter, the value of color is changing to null, in one straight table and in other the extra values are coming.

The requirement is i should get the output as ARGB(255,255,0,0) with no extra row, when i select A.

Please assist.

Regards,

MK !

Anonymous
Not applicable
Author

I have added the application.

sunny_talwar

This?

Capture.PNG

Anonymous
Not applicable
Author

yes, but how did you get this.

Anonymous
Not applicable
Author

Ok, i got it.

sunny_talwar

I attached the application. Used this expression:

If(sum(Vol) > 0,

ColorMix1 ((1+Sign(2*(sum({<state=>}Vol)-RangeMin (top(total sum({<state=>}Vol),1,NoOfRows(total))))/(RangeMax (top(total sum({<state=>}Vol),1,NoOfRows(total)))-RangeMin (top(total sum({<state=>}Vol),1,NoOfRows(total))))-1)*Sqrt(Fabs((2*(sum({<state=>}Vol)-RangeMin (top(total sum({<state=>}Vol),1,NoOfRows(total))))/(RangeMax (top(total sum({<state=>}Vol),1,NoOfRows(total)))-RangeMin (top(total sum({<state=>}Vol),1,NoOfRows(total))))-1))))/2, ARGB(255, 255, 0, 0), ARGB(255, 0, 255, 0)))

As soon as you make a selection in State Sum(Vol) becomes 0 and all other rows for colormix become null

HTH

Best,

Sunny

sunny_talwar

Awesome

If you got what you wanted would you be able to close this thread by marking the correct answer and/or mark any useful answers.

Best,

Sunny