This really was a "moment" on my end - What I missed was imputing in the "By" Field when setting the Top X filter on the Bars field.
This makes total sense and was something I fundamentally knew, but was just missing.
Original Message:
Sent: Wed November 15, 2023 03:39 AM
From: Marc Reed
Subject: Top X for Stacked Bar/Column Chart
Henk's suggestion normally works!
Here is an example on Go Sales.
This chart has 12 bars:

Apply a Top filter as such:

shows this:

Performance will be down to the underlying datasource, rather than the dashboard tool itself. In this simple example, if you examine the sql that the database is doing you'll see the Dense Rank function, and then <5, to get the top 4

Someone with some C12 knowledge may be able to comment if Top X functionality is covered in the new dashboard local cache capability.
there is nothing in the c12 docs that say it is/isnt.
https://www.ibm.com/docs/en/cognos-analytics/12.0.0?topic=caching-specifying-data-elements-local
------------------------------
Marc Reed
Original Message:
Sent: Tue November 14, 2023 09:39 AM
From: Adam McIlravey
Subject: Top X for Stacked Bar/Column Chart
Henk...
Thanks for the suggestion
I have previously tried this (putting a Top X filter on Practice Name - Bars) and it appears to do nothing.
Or it is potentially taking way too long to do anything to the point where use in a dashboard would be meaningless.
Another indication that it is doing nothing is that it does not create a Widget Filter for Top 10 similar to when I do it on the Amount - Length field.
Any other suggestions would be much appreciated.
Thanks again,
------------------------------
Adam McIlravey
Original Message:
Sent: Mon November 13, 2023 05:49 PM
From: HENK CAZEMIER
Subject: Top X for Stacked Bar/Column Chart
Hi Adam,
Have you tried to apply the top-operation to the Bars slot?
------------------------------
Kind regards,
Henk Cazemier
Original Message:
Sent: Mon November 13, 2023 01:34 PM
From: Adam McIlravey
Subject: Top X for Stacked Bar/Column Chart
CA 11.1.7
In a Dashboard or Exploration, I have a Stacked Bar chart defined as follows:
- Bars - Practices
- Colors - Service Types
- Length - Amount
The list contains far too many practices to be useful, so I want to reduce to a Top 10/20 etc.
What I want to get is the Top X Practices by Total Amount and their associated Service Types by color.
There can only be a maximum of 4 Types for each Practice.
However, when I put a Top Count on Amount, I believe I am getting the largest 10 Types and their associated practices.
It is only showing 4 practices with what appear to be the largest 10 types by Practice - Based on the data what I am seeing makes sense for the Top 10 Types by Amount and their associated Practices, but clearly not what I want!
Am I missing something simple?
In my opinion, I don't think I should have to create a rank in the Data Module to enable this functionality.
Thanks in advance,
------------------------------
Adam McIlravey
------------------------------