Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.

Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Qlik Community
- :
- Forums
- :
- Analytics
- :
- New to Qlik Analytics
- :
- 100% Stacked Bar Chart using multiple measures

Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

klrameet

Contributor III

2020-08-30
12:59 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

100% Stacked Bar Chart using multiple measures

i am trying to plot a 100% stacked bar chart, showing the variance across three categories for each group and it was relatively automatic and easy in excel to plot ..

but when i tried to same in qlik sense .. this is what i am getting, i tried using total function but still no luck.

sum([Taken])/sum(TOTAL<Group> [taken])

sum([Planned])/sum(TOTAL<Group> [Planned])

sum([Open])/sum(TOTAL<Group> [Open])

Any pointers would be helpful

@JonnyPoole @Anonymous

3,747 Views

1 Solution

Accepted Solutions

jwjackso

Specialist III

2020-08-30
02:25 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Using the following data:

Data:

Load * Inline [

Code,TAKEN,PLANNED,BALANCE

ABC,10,50,10

DEF,12,12,56

GHI,5,5,14

];

Formula for % TAKEN

=Sum(TAKEN)/(SUM(TAKEN)+SUM(PLANNED)+SUM(BALANCE))

Formula for % PLANNED

=Sum(PLANNED)/(SUM(TAKEN)+SUM(PLANNED)+SUM(BALANCE))

Formula for % BALANCE

=Sum(BALANCE)/(SUM(TAKEN)+SUM(PLANNED)+SUM(BALANCE))

Set the presentation to be a stacked bar chart

3,711 Views

2 Replies

jwjackso

Specialist III

2020-08-30
02:25 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Using the following data:

Data:

Load * Inline [

Code,TAKEN,PLANNED,BALANCE

ABC,10,50,10

DEF,12,12,56

GHI,5,5,14

];

Formula for % TAKEN

=Sum(TAKEN)/(SUM(TAKEN)+SUM(PLANNED)+SUM(BALANCE))

Formula for % PLANNED

=Sum(PLANNED)/(SUM(TAKEN)+SUM(PLANNED)+SUM(BALANCE))

Formula for % BALANCE

=Sum(BALANCE)/(SUM(TAKEN)+SUM(PLANNED)+SUM(BALANCE))

Set the presentation to be a stacked bar chart

3,712 Views

barnabyd

Partner - Creator III

2020-08-30
07:51 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Here's another solution. It might not be suitable, but it's good to know that it's available.

Use crosstable to convert the three columns into another dimension and then you have two dimensions and only one measure on your stacked bar chart.

Then you only need one formula:

=Sum(Value) / sum( total<Code> Value )

Barnaby Dunn

BI Consultant

BI Consultant

Community Browser