Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
2 years ago
Solved

Create a Distribution chart by bucketizing a measure

Hello friends. Imagine my scenario as part of Supply Chain data where users are ordering items.       In this table, I created "Average (days)" as a measure that calculates the average days...
  • gmsamborn's avatar
    gmsamborn
    2 years ago

    Hi Anonymous 

     

    I created a bucket table with 3 columns: Bucket (ie. 0-10), Min(0) and Max (10) for each bucket.

     

    I wrote 1 measure.

     

    Count = 
        COUNTROWS(
            FILTER(
                ALL( 'Table' ),
                'Table'[Average (days)] >= SELECTEDVALUE( 'Buckets'[Min] )
                    && 'Table'[Average (days)] <= SELECTEDVALUE( 'Buckets'[Max] )
            )
        )

     

     

    The ALL() might have to be changed to ALLSELECTED() depending on your needs.

     

    Let me know if you have any questions.

     

    Create a Distribution chart by bucketizing a measure.pbix