I’m trying to do a “time to convert” funnel analysis which looks at the duration between the first instance of an event and the last instance of an event.Â
This is kind of a proxy for session duration, or dwell time, but it’s more flexible for our use case because it can span multiple sessions (as they’re defined by Amplitude).Â
When I try to do this as a funnel showing time to convert, it just gives me the time to convert between the First event and the next instance of that event.Â
How can I calculate the time between the First and Last occurrence of that event, with an unknown number of other events (including that same event) happening between those two bookends?Â
Â

Â
More examples:Â

Â
Here, in between the first and last event, any number of events could happen, including more of the same, for an undetermined amount of time.Â
Â

For this case, the correct answer to “time to convert” should be roughly 2 hours 16 minutes (not 2 minutes, because that is the next instance of this event.Â