Forum Discussion

klq9386's avatar
klq9386
Regular Visitor
9 years ago

median calculated column

I am trying to do math for the median of a high and low for each value in a financial report that each have a min and max. I want to use median or something and cant figure it out. 

 

What I have so far

 

 Table.AddColumn(#"Replaced Value", "SC", each MEDIAN(.90, 1.10, [DTV Net])*.4+MEDIAN(.90, 1.10,[COL1])*.2+MEDIAN(.90, 1.10,[COL2])*.2+MEDIAN(.90, 1.10,[COL3])*.1+MEDIAN(.90, 1.10,[COL4])*.1)

 

Each column has a floor and celing of 90/110 and then a weight to get the total score. 

 

Thoughts on how I can do this in a custom column?

3 Replies

  • klq9386's avatar
    klq9386
    Regular Visitor

    Tried using floor and celing but those arent recognized in calculated columns

    • MarcelBeug's avatar
      MarcelBeug
      Community Champion

      Are you looking for a DAX solution ("Calculated column") or a Power Query solution ("Custom column")?

       

      The formula in your first post is a mix of Power Query and DAX.

       

      Otherwise you'd better provide an example with input, expected output and explanation how the expected output is derived from the input.

      The information so far, is rather confusing.

  • v-qiuyu-msft's avatar
    v-qiuyu-msft
    Community Support

    Hi klq9386,

     

    Agree with MarcelBeug. Please share some sample data and expected results, so that we can understand your requirement better and give a prompt response.

     

    Best Regards,
    Qiuyun Yu