Forum Discussion

mianjalil239's avatar
mianjalil239
Icon for Helper III rankHelper III
1 year ago

Who is the master

 I need in average not in sum red box 

1 Reply

  • Hi mianjalil239 

     

    try somthing like this:

    EB Avg = 
    AVERAGEX (  
        // Iterate over a table created by SUMMARIZECOLUMNS  
        SUMMARIZECOLUMNS (  
            'table'[description],  // Group by 'description' column  
            'table'[batch],        // Group by 'batch' column  
            'table'[coliform],     // Group by 'coliform' column  
    
            // Define a new column "@value" that calculates the sum of 'table'[EB]  
            "@value", CALCULATE ( SUM ( 'table'[EB] ) )  
        ),  
    
        // Calculate the average of the "@value" column from the summarized table  
        [@value]  
    )  
    

    T