Forum Discussion
Breaking down the normal distribution by attributes
- 6 years ago
Hi Anonymous ,
First of all, your model relationship may be a bit problematic, it should be like this:
Secondly, the results returned by your two percentage measures may have problems, please refer to the following formula:
Percent of respondents = VAR x = CALCULATE( DISTINCTCOUNT('Sample'[External Data Reference]), ALLEXCEPT( 'Sample', 'Sample'[Sector] ) ) VAR y = CALCULATE( DISTINCTCOUNT('Sample'[External Data Reference]), ALL('Sample') ) RETURN DIVIDE( x, y, BLANK() ) Percent of total Population = VAR x = CALCULATE( DISTINCTCOUNT(Population[ID]), ALLEXCEPT( 'Population', 'Population'[Sector] ) ) VAR y = CALCULATE( DISTINCTCOUNT(Population[ID]), ALLSELECTED('Sample'[Sector]) ) RETURN DIVIDE( x, y, BLANK() )Left_Tailed_Hypothesis = NORM.DIST( [Percent of respondents], [Percent of total Population], 1, TRUE() )The value of COUNTROWS(ALLSELECTED('Sample')) is too big, which is not suitable for Standard_dev parameters.And its value is equal to a fixed value 899.You can refer to https://docs.microsoft.com/en-us/dax/norm-dist-dax to learn NORM.DIST() function.Best regards,
Lionel ChenIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Sorry, really bad spelling on my behalf in my previous post. What I meant to ask was, why have you included ALLSELECTED in your measures?
I created a sample report, and I can't replicate the behaviour you are experiencing. Could you share your report, or create sample report where you reproduce the behaviour you are experiencing?
Cheers,
Sturla
Hey sturlaws ,
I was using the ALLSELECT() to gain a dynamic percentage of total.
I've created a dummy replicar in the PBI file where I am still experiencing the same issue :(... can't seem to figure out how to attach it to the thred though?
Thanks again!
Polly
- sturlaws6 years ago
Resident Rockstar
Adding files in this forum is a bit awkward, you have to upload the file to onedrive/dropbox/other and share the link here- Anonymous6 years agoNot applicable
Hi sturlaws ,
Ah i see, here you go go https://www.dropbox.com/s/chdqh4454426nvt/Normal%20Distribution.pbix?dl=0
Thanks,
Polly
- v-lionel-msft6 years ago
Community Support
Hi Anonymous ,
First of all, your model relationship may be a bit problematic, it should be like this:
Secondly, the results returned by your two percentage measures may have problems, please refer to the following formula:
Percent of respondents = VAR x = CALCULATE( DISTINCTCOUNT('Sample'[External Data Reference]), ALLEXCEPT( 'Sample', 'Sample'[Sector] ) ) VAR y = CALCULATE( DISTINCTCOUNT('Sample'[External Data Reference]), ALL('Sample') ) RETURN DIVIDE( x, y, BLANK() ) Percent of total Population = VAR x = CALCULATE( DISTINCTCOUNT(Population[ID]), ALLEXCEPT( 'Population', 'Population'[Sector] ) ) VAR y = CALCULATE( DISTINCTCOUNT(Population[ID]), ALLSELECTED('Sample'[Sector]) ) RETURN DIVIDE( x, y, BLANK() )Left_Tailed_Hypothesis = NORM.DIST( [Percent of respondents], [Percent of total Population], 1, TRUE() )The value of COUNTROWS(ALLSELECTED('Sample')) is too big, which is not suitable for Standard_dev parameters.And its value is equal to a fixed value 899.You can refer to https://docs.microsoft.com/en-us/dax/norm-dist-dax to learn NORM.DIST() function.Best regards,
Lionel ChenIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.