3 Replies Latest reply on May 23, 2018 7:35 AM by Deepak Rai

# Table calculation: divide by diagonal value (or column maximum)

Hi!

First time posting in the forum, so, sorry before hand for any mistakes made.

Im currently trying to analize cross sales for two different product lines. To make the comparation we use a table like this.

So in an attempt to make the visualization easier to read for a client I'd like to show the values as a porcentage, but it would need to be based on the diagonal value (which by definition will also be the maximum of the column), so I need to divide all the values by its columns maximum value ( the corresponding diagonal value). In excel, where it is currently done, it would look like this:

, (note that these second values are not the same ones as shown above, but it's the same idea).

This says that 25% of the people that bought in the J0407 line also bought in J0406. (highlighted)

Does anyone know hot to do it?

Kind Regards,

SB.

• ###### 1. Re: Table calculation: divide by diagonal value (or column maximum)

{FIXED Cat 1,Cat2: SUM(Value)}/{FIXED Cat2:MAX(Value)}

1 of 1 people found this helpful
• ###### 2. Re: Table calculation: divide by diagonal value (or column maximum)

Deepak, thanks a lot for the answer!

Although it didn't seem to work just like that, I understood your logic, and ended up using the following code:

{ FIXED [Cat 1],[Cat 2]: SUM([value])}/{ FIXED [Cat 2]: MAX({ FIXED [Cat 1],[Cat 2]: SUM([value])})}

The only difference is that on the denominator the division uses the max of the numerator, instead of 'value' itself.

Hope this helps someone else with the same doubt.

Regards,

SB.

1 of 1 people found this helpful
• ###### 3. Re: Table calculation: divide by diagonal value (or column maximum)

Great!! Pl close the thread to help someone