Ideas on how to build a history timeline

I’m going to have a lot of data, mostly numbers logged by date/time, going back a long way.

What I’d like to do is display them in a sort of timeline, but not every single detail, more like the average number for a time period. Like, if you logged your body weight every day for a year, you’d be able to see that history as your average weight each week, or each month.

So I think what I need is a list of date ranges that cover the entire time period that the data itself covers. That list can be in a repeating group, then each cell of the repeating group would have a date range, so I could search the log for entries in that date range and average their values.

But how do I get a list of date ranges? Is there a better way to organize this?

Is it worth creating these as a separate table with a defined set of values?

The concept that comes to mind is to create a thing called “Campaigns” (where a campaign has a defined start date and end date). It can have a type (Week, Month, etc). The Campaign itself can store a list of logged items.

The campaign can be an active process (ie. the user says for the next 30 days) or a background process (ie. at the start of each week, you have a recurring workflow that creates a new “Active” campaign and moves the prior one to a “Completed” status).

I’m hoping to find a way to do it dynamically so it can be adjusted, rather than being locked in to an arbitrary time period.

2 Likes