cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
PBI_Rookie
Frequent Visitor

Control Charting-ALLSELECTED

Hello All,

 

I've previosuly created control charts using a dataset with only the data needed. I am now trying to use the same measures to create the control charts where the data needed is only a subset. 

 

I am using 4 measures, the two below and one to make the upper and lower limits. 

 

ControlChart Average = CALCULATE(AVERAGEX(TABLE, COLUMN with data needed),ALLSELECTED(Identifier I want to sort by]))
 
ControlChart STDDev = CALCULATE(STDEVX.P(Table],column with data needed),ALLSELECTED(identifier i want to sort by)
 
My issue is that while I'm getting the correct values, my chart is including identifiers that aren't tied to the data. My x-axis is the sample field used in the ALLSELECTED. 
 
If I use ALLSELECTED I get x-axis labels that aren't relevant. If I don't use ALLSELECTED I get the values calculated for each datapoint and not the whole range. 
 
Without ALLSECLTED
PBI_Rookie_0-1630260010552.png

 With ALLSELECTED

PBI_Rookie_1-1630260118112.png

 

 Any suggestions?
 
Thanks
1 ACCEPTED SOLUTION

I was finally able to get this to work. 

 

I used AllSELECTED as I described initially. What I had to do to make it work however was to duplicate my source table and filter it to be only the needed information. In this case the sample IDs. 

View solution in original post

7 REPLIES 7
v-caitlyn-mstf
Community Support
Community Support

Hi @PBI_Rookie ,

 

Has your problem been solved? If it has been solved, please accept the correct reply as the standard answer to help the other members find it more quickly.Thank you very much for your kind cooperation!

 

 

 

 

 

Community Support Team _ Caitlyn Yan


If this post helps then please consider Accept it as the solution to help the other members find it more quickly.

 

 

 

littlemojopuppy
Super User
Super User

Hi!  Try changing ALLSELECTED() to KEEPFILTERS(Identifier I want to sort by]).

Hi, 

 

Ok I tried replacing the ALLSLECTED in both measures with KEEPFILTERS. I get an error that "Cannot convert value (identifier) of type TEXT to type True/False"

 

 

😮  Well that is certainly an unusual error message...

 

Can you provide some sample data to play with?

Playing with KeepFilters a bit I can see why it is giving me that error. If I alter it a bit i.e. KeepFilters(Column="") i will not get the error. Unfortunately it also does not solve the initial issue. 

I think I was a little off...try KEEPFILTERS() with whatever is on the X axis

I was finally able to get this to work. 

 

I used AllSELECTED as I described initially. What I had to do to make it work however was to duplicate my source table and filter it to be only the needed information. In this case the sample IDs. 

View solution in original post

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

November Power BI Update 768x460.png

Check it Out!

Click here to read more about the November 2021 Updates!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.