Ratios in Graph

I have a field called โ€œRatioโ€ that is calculated by dividing field A by field B. When I make the graphs I donโ€™t find the way to calculate the โ€œRatioโ€ field for a group of data, because it is not the average โ€œRatioโ€ of each cell. The correct โ€œRatioโ€ must be the result of the sum of the A fields between the sum of the B fields. Is it possible that AppSheet correctly calculates this case?

0 7 403
  • UX
7 REPLIES 7

Are you able to take a printscreen from that situation?

Hi Aleksi:
The situation is that in graph I can show a ratio of one event but I canโ€™t show a monthly ratio, because it is not al sum of ratios or average of ratio. Look this example:

In my app only existe this part:
Field A Field B Ratio
Record 1 30 10 3
Record 2 49 7 7
Record 3 10 5 2

Then you have the following options to show in a graph the ratio of all period:
SUM: 11 (3+4+4) is not correct
AVERAGE: 4 ((3+7+2)/3) is not correct
THE CORRECT ANSWER IS 4.05 ((30+49+10)/(10+7+5))
Is possible that AppSheet shows the correct answer in a graph?

Steve
Platinum 5
Platinum 5

Something like this?

(
  SUM(
    SELECT(
      MyTable[FieldA],
      ...
    )
  )
  / SUM(
    SELECT(
      MyTable[FieldB],
      ...
    )
  )
)

Thanks for your answer Steve.

My problem is that I canโ€™t get that a graph give me de correct answer. Look this example:

In my app only existe this part:
Field A Field B Ratio
Record 1 30 10 3
Record 2 49 7 7
Record 3 10 5 2

Then you have the following options to show in a graph the ratio of all period:
SUM: 11 (3+4+4) is not correct
AVERAGE: 4 ((3+7+2)/3) is not correct
THE CORRECT ANSWER IS 4.05 ((30+49+10)/(10+7+5))
Is possible that AppSheet shows the correct answer in a graph?

Change all of your column types from Number to Decimal.

Thanks Steve, but it is not problem of format. Is the way that AppSheet calculate ratios

I donโ€™t see the option to calculate a ratio, so it doesnโ€™t appear to me that the problem is โ€œthe way AppSheet calculate ratiosโ€, but rather that it doesnโ€™t calculate ratios. Are youโ€™re asking that AppSheet add a RATIO option to the Group Aggregate property?

Top Labels in this Space