Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Christopher_Lawrence
Contributor III
Contributor III

Stacked Column Graph w/ Set Analysis?

I am currently attempting to create a stacked bar graph that showcases the count of users (stacked by role) that the application had, grouped by month. What I mean by this is that for the month of January, the January column should have the count of all users (stacked by role) created on or before the 31st of January. The February column should have the cumulative count of all users created on or before the 28th of February, and so on/so forth. (Example of raw data attached)

However, I do also have a variable I made $(vReportRangeSet) that is leveraged in graphs as this is what allows the user to utilize a filter saying "display last 3 full month, display last 6 full months" etc. For consistency, I will need to also have this included, otherwise I would need to display a rolling 12 months of data if this cannot be incorporated. 

Would anyone have an idea of the logic that would be used to accomplish this?

 

Labels (3)
2 Replies
GaryGiles
Specialist
Specialist

See attached qvf.  Not sure the exact definition of your variable, but I implemented a set analysis variable that should adjust the chart if it is changed to include 6 months, instead of 3.  The trick is to use the Accumulation Modifer in the definition of the measure.

GaryGiles
Specialist
Specialist

I realized that the starting month's count would not include prior months User IDs when using the set analysis varables.  Added a couple of technique to get the starting month value to be correct while not displaying previous months.  Again, this depends on the set up of your vReportRangeSet variable.  You may need to setup an additional variable to control what months are displayed.