Versions in this module Expand all Collapse all v1 v1.0.0 Aug 28, 2026 Changes in this version + const KmPerMile + var ActivityLevels = map[string]float64 + func BMI(kg, cm float64) (float64, error) + func BMRKatchMcArdle(leanBodyMassKg float64) (float64, error) + func BMRMifflinStJeor(sex Sex, kg, cm, age float64) (float64, error) + func BodyFatNavy(in NavyInput) (float64, error) + func BodySurfaceArea(kg, cm float64, formula BSAFormula) (float64, error) + func FormatDuration(seconds float64) (string, error) + func LeanBodyMassBoer(sex Sex, kg, cm float64) (float64, error) + func LeanBodyMassFromBodyFat(kg, bodyFatPct float64) (float64, error) + func MaxHeartRate(age float64, formula HRFormula) (float64, error) + func WaistToHeightRatio(waist, height float64) (float64, error) + type BSAFormula string + const DuBois + const Gehan + const Haycock + const Mosteller + type FFMIResult struct + FFMI float64 + FatFreeMassKg float64 + Normalised float64 + func FFMI(kg, cm, bodyFatPct float64) (FFMIResult, error) + type HRFormula string + const Classic + const Tanaka + type HRMethod string + const Karvonen + const Percentage + type NavyInput struct + HeightCm float64 + HipCm float64 + NeckCm float64 + Sex Sex + WaistCm float64 + type OneRepMaxResult struct + Average float64 + Brzycki float64 + Epley float64 + func OneRepMax(weight float64, reps int) (OneRepMaxResult, error) + type PaceResult struct + KmPerHour float64 + MilesPerHour float64 + SecondsPerKm float64 + SecondsPerMile float64 + func Pace(km, seconds float64) (PaceResult, error) + type Sex int + const Female + const Male + func ParseSex(s string) (Sex, error) + func (s Sex) String() string + type TDEEResult struct + BMR int + Multiplier float64 + TDEE int + func TDEE(sex Sex, kg, cm, age, multiplier float64) (TDEEResult, error) + func TDEENamed(sex Sex, kg, cm, age float64, activity string) (TDEEResult, error) + type TargetHeartRateResult struct + BPM int + HRMax int + Method HRMethod + func TargetHeartRate(age, intensity, restingHr float64, formula HRFormula) (TargetHeartRateResult, error)