dive-math / oxygen / cnsRunningTotals
Function: cnsRunningTotals()
cnsRunningTotals(
exposures,opts?):CnsTotals[]
Defined in: oxygen.ts:225
cnsTotals after each exposure, in one pass: element i equals cnsTotals(exposures.slice(0, i + 1), opts) exactly.
Parameters
exposures
readonly Exposure[]
opts?
daily?
boolean
limits?
Returns
Example
ts
cnsRunningTotals([{ ppo2: 1.4, minutes: 30 }, { ppo2: 1.4, minutes: 30 }]).map((t) => t.cnsPercent) // [20, 40]