Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
deeavhad
Contributor
Contributor

Color the Bar in bar chart as per previous bar value

For bar chart my x-axis has months and y axis has calculated value, so I want to color current month bar based on previous month bar value. e.g. for previous month bar value is 50 and for current month bar value is 45 then current month bar should be green

Labels (1)
1 Solution

Accepted Solutions
rubenmarin

Hi, you can use Above() to retrive the presious bar value, so if you rexpression is "Sum(Amount)", the color expresion could be "If(Sum(Amount)<Above(Sum(Amount)), Green(), Red())" 

View solution in original post

1 Reply
rubenmarin

Hi, you can use Above() to retrive the presious bar value, so if you rexpression is "Sum(Amount)", the color expresion could be "If(Sum(Amount)<Above(Sum(Amount)), Green(), Red())"