Skip to main content
Announcements
Live today at 11 AM ET. Get your questions about Qlik Connect answered, or just listen in. SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to create a flexible Baseline in chart?

Hi All, I am a fresh developer of Qlikview. I meet a question during developing and hope any one could help me to find a solution.

Now I have created a Bar Chart which shows the Sales Value rolling back 12 months from current month. However, I also should create a BaseLine in this chart which show the Max Sales Value of these 12 months. As you know, the month always change and the value will change too. So, how can I create a flexible baseline which can both show the max sales value of month and vary with time?

Thanks a lot.

1 Solution

Accepted Solutions
swuehl
MVP
MVP

Not sure how this baseline should look like, but you could try creating a reference line in presentation tab of your bar chart properties, enter as expression for this reference line

=max(aggr(sum(Sales), Month))

I assume Month is your field you are using as dimension in your chart.

How have you limited your chart to the last 12 months? Using a calculated dimension? Then you probably don't need to do anything else.

If you have limited the data using set analysis in your expression, you probably need to add this set expression to your aggr() expression, too, like

=max({SETEXPRESSIONGOESHERE} aggr(sum({SETEXPRESSIONGOESHERE}Sales), Duration))

Or maybe I have misunderstood your requirement, if so, please add some more information.

View solution in original post

2 Replies
swuehl
MVP
MVP

Not sure how this baseline should look like, but you could try creating a reference line in presentation tab of your bar chart properties, enter as expression for this reference line

=max(aggr(sum(Sales), Month))

I assume Month is your field you are using as dimension in your chart.

How have you limited your chart to the last 12 months? Using a calculated dimension? Then you probably don't need to do anything else.

If you have limited the data using set analysis in your expression, you probably need to add this set expression to your aggr() expression, too, like

=max({SETEXPRESSIONGOESHERE} aggr(sum({SETEXPRESSIONGOESHERE}Sales), Duration))

Or maybe I have misunderstood your requirement, if so, please add some more information.

Not applicable
Author

Hi swuehl, thank you a lot. That's what I want. It works successfully.