def METHOD_NAME(self, context):
    loop_group_names = ["90th Percentile", "95th Percentile", "99th Percentile", "Jank", "Jank%"]
    count = 0
    p = re.compile("Frames: \d+ latency: (?P<pct90>\d+)/(?P<pct95>\d+)/(?P<pct99>\d+) Janks: (?P<jank>\d+)\((?P<jank_pct>\d+)%\)")
    for line in self.output.strip().splitlines():
        match = p.search(line)
        if match:
            if line.startswith("AVE: "):
                group_names = ["Average " + g for g in loop_group_names]
                classifiers = {"loop": "Average"}
            else:
                count += 1
                group_names = loop_group_names
                classifiers = {"loop": count}
            for (name, metric) in zip(group_names, match.groups()):
                context.add_metric(name, metric,
                                   classifiers=classifiers)