Marathon pacing — cardiac drift, hydration, sodium
pacing_strategySimulate marathon HR drift and fluid/sodium balance under given heat, sweat, and aid-station conditions. Returns total drift split by cause, decoupling %, kilometre at LT₂ breach, the kilometre where holding pace would demand more than HRmax, plasma sodium, and body-weight loss. Pace at the target %HRR is derived from the athlete's own VO₂max and cost of running, so supply marathonPr or vo2max for a pace specific to them. Source: ham.run HR pacing module. Pass useMyData:true to overlay age + restingHr + weight + VO₂max + PR from the connected athlete profile.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| age | No | Age in years. | |
| sex | No | Athlete sex — affects sweat rate and thermoregulation. | |
| maxHr | No | Measured maximum heart rate, bpm. Falls back to age-predicted if omitted. | |
| tempC | Yes | Air temperature, °C. | |
| hrRest | No | Resting heart rate, bpm. | |
| vo2max | No | Used to derive pace at the target %HRR when no marathon PR is given. | |
| useMyData | No | Overlay age, resting HR, and weight from the connected athlete profile. | |
| marathonPr | No | Marathon PR. Preferred over vo2max for deriving pace: the athlete's cost of running is back-solved from it, so their marathon-effort intensity reproduces this time exactly. | |
| bodyWeightKg | No | Body weight in kilograms. | |
| intensityPct | Yes | Target effort as % of HRR. | |
| fluidPerStationMl | Yes | Fluid intake per aid station, mL. | |
| sodiumPerStationMg | Yes | Sodium intake per aid station, mg. | |
| sweatSodiumMmolPerL | Yes | Sweat sodium concentration in mmol/L (typical 30–60). | |
| baselineSweatRateLPerHr | Yes | Baseline sweat rate, L/hr. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| lt1 | Yes | LT1 heart rate, bpm. | |
| lt2 | Yes | LT2 heart rate, bpm. | |
| hrMax | Yes | Age-predicted or measured max HR, bpm. | |
| input | Yes | Echo of resolved input parameters. | |
| hrStart | Yes | Starting HR at target intensity, bpm. | |
| pacingKmh | Yes | Average pacing speed, km/h. | |
| finishTime | Yes | Predicted finish time. | |
| paceSource | Yes | What the pace was derived from. "assumed" means neither marathonPr nor vo2max was supplied and a recreational reference VO₂max was used — say so when reporting the finish time. | |
| vo2maxUsed | Yes | VO₂max the pace was derived from, mL·kg⁻¹·min⁻¹. | |
| checkpoints | Yes | 5-km checkpoint data. | |
| hrCeilingKm | Yes | Kilometre from which holding this pace would demand a heart rate above HRmax, or null. Non-null means the pace is not sustainable: the athlete slows instead. | |
| lt2BreachKm | Yes | Kilometre where HR breaches LT2, or null. | |
| decouplingPct | Yes | Cardiac decoupling, %. | |
| finalPlasmaNa | Yes | Final plasma sodium, mmol/L. | |
| totalDriftBpm | Yes | Total cardiac drift over the marathon, bpm. | |
| driftBpmByCause | Yes | Total drift split by cause. Decoupling % alone conflates pacing strain with dehydration, and the two move in opposite directions with intensity. | |
| pctBodyWeightLost | Yes | Body weight lost, %. | |
| dominantDriftCause | Yes | Which cause contributes the most drift. | |
| totalFluidDeficitL | Yes | Total fluid deficit at finish, L. | |
| marathonEffortPctHrr | Yes | The %HRR that reproduces this athlete's marathon-effort oxygen uptake — their marathon race intensity. | |
| totalSodiumDeficitMg | Yes | Total sodium deficit at finish, mg. | |
| actualSweatRateLPerHr | Yes | Temperature-adjusted sweat rate, L/hr. |