Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
KDS
Helper I
Helper I

Scatterplot - fixed marker size

I have a scatterplot for which the marker size is based on the count of IDs by category.  The categories are also used in legend and filter. 

IDCatxY
1A00
2A00
3B00
4A22.746.05
5C73.776.91
6A73.795.16
7B11.375.56
8B28.30
9C85.00

 

The issue I'm having is that when a filter is applied to view only one of the subcategories, the size of the markers change.  How do I adjust my formula so that the size is not affected by a filter?

 

Size = CALCULATE(SUM(Table1[ID]),ALLEXCEPT(Table1,Table1[Cat]))

 

Thanks!

 

3 REPLIES 3
TheoC
Super User
Super User

Hi @KDS 

 

The current measure you're using is using SUM to add all of the IDs together.  Are you able to switch this to a COUNT?

Size = CALCULATE ( COUNT( Table1[ID] ) , ALLEXCEPT ( Table1 , Table1[Cat] ) )

Below is without Cat filter applied:

 

TheoC_0-1651822391878.png

Here is with Cat applied:

TheoC_1-1651822441859.png

I hope this is what you were wanting?  If not, let me know. PBIX is also attached.


Thanks heaps,

Theo

 

 

If I have posted a response that resolves your question, please accept it as a solution to formally close the post.

Also, if you are as passionate about Power BI, DAX and data as I am, please feel free to reach out if you have any questions, queries, or if you simply want to connect and talk to another data geek!

Want to connect?www.linkedin.com/in/theoconias

@TheoC Thanks for your reply.  I don't know why I typed Sum in my question, count is what I actually have in my formula But every time I filter on category it resizes the markers.  I think my issue is that the category is also in my legend to differentiate the different markers. When I added the categories to the legend in your example, I ran into the same issue I'm having in mine -- it resizes when I filter on category.

 

Also, mine was set up differently (this was created by someone else - I'm just trying to find a solution to the problem stated above) ... I have values blank, and  X & Y are set to do not summarize, and cat in the legend.  The only reference to ID is in the formula for the bubble size. 

 

 

Hi @KDS 

 

No worries at all. If you set up your Scatter like follows, your problem should be fixed:

Below is unfiltered screenshot:

TheoC_0-1651880579810.png

Here is a filtered screenshot:

TheoC_1-1651880631537.png

It should achieve what you are after in that you have the "size" and "legend" showing on the unfiltered scatter, and then the filtered removes the issue with the resizing.

 

Hope this helps! 

 

Theo 🙂

 

 

If I have posted a response that resolves your question, please accept it as a solution to formally close the post.

Also, if you are as passionate about Power BI, DAX and data as I am, please feel free to reach out if you have any questions, queries, or if you simply want to connect and talk to another data geek!

Want to connect?www.linkedin.com/in/theoconias

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.