Here's what I came up with using the R chat:
ride = GC.activity()
i = 0
work = 0
for (pwr in ride$power) {
i = i + 1
work = work + pwr
if (work > 1000000) {
break
}
}
residue = ride$power[i:length(ride$power)]
best=paste(round(max(rollmean(residue, 300))), "W")
plot(rollmean(residue, 300), xlab=best)
Ideally I'd find a way to extract this metric for every ride and then plot it as Mean Max chart to find what my bests are after 1000 kJ of work (as opposed to fresh).