Doing "complex" math & visualizing data

Hi - For an OKR application, I am trying to calculate and visualize the progress of Key Results and their parent objectives.

The data is set-up as follows:

  1. While I can calculate the current progress of an individual Key Result, how could I show the progress over time?

  2. Also, the progress of an objective should be calculated as the average of the progress of all corresponding Key Results last progress. The formula would be smth like this Avg(last_progress.key_result1, last_progress.key_result2…)

  3. Similarly to #1, how can I calculate/visualize the progress over time of the respective Objective. Basically, each time a Result is added, a Key Result is updated and a new data point at the objective progress timeline is created.

In smth like google sheets this would be extremely easy, but I am having a hard time figuring this out with bubble.

Thanks a lot!!!