Total 5xx/4xx % calculation

Use cloudwatch math expressions. Use search forum function and you will find topics about it, e. g. Disappointing First Experience with Grafana - can't do simple math? - #8 by jangaraj