wilks-calculator

1.2.4 • Public • Published

wilks-calculator

This library calculates performs calculations with the Wilks coefficient, which is a coefficient used by the International Powerlifting Federation to determine the relative strength of competitors. They also use this coefficient for determining the qualification requirements for championships.

Build Status npm version Coverage Status

Installation

npm install wilks-calculator

Usage

const wilksCalculator = require('wilks-calculator')

wilksCalculator.calculateWilksScore(gender, bodyWeight, liftedWeight, [unitType]);
  • gender (string) - 'm' for Male and 'f' for Female
  • bodyWeight (number)
  • liftedWeight (number)
  • unitType (string) - 'metric' or 'imperial' (optional)
wilksCalculator.calculateWeightToLift(gender, bodyWeight, wilksScore, [unitType]);
  • gender (string) - 'm' for Male and 'f' for Female
  • bodyWeight (number)
  • wilksScore (number)
  • unitType (string) - 'metric' or 'imperial' (optional)
wilksCalculator.calculateNeededBodyWeight(gender, liftedWeight, wilksScore, [unitType]);
  • gender (string) - 'm' for Male and 'f' for Female
  • liftedWeight (number)
  • wilksScore (number)
  • unitType (string) - 'metric' or 'imperial' (optional)

Examples

calculateWilksScore

var femaleWilksScore = calculateWilksScore('f', 60, 300);
// Returns 334.47

var maleWilksScore = calculateWilksScore('m', 90, 500);
// Returns 319.20

var femaleImperialWilksScore = calculateWilksScore('f', 132, 660, 'imperial');
// Returns 334.31

var maleImperialWilksScore = calculateWilksScore('m', 176, 882, 'imperial');
// Returns 273.49

calculateWeightToLift

var femaleTotal = calculateWeightToLift('f', 60, 350);
// Returns 313.93 (kg)

var maleTotal = calculateWeightToLift('m', 80, 350);
// Returns 512.67 (kg)

var femaleImperialTotal = calculateWeightToLift('f', 132, 660, 'imperial');
// Returns 690.97 (lbs)

var maleImperialTotal = calculateWeightToLift('m', 176, 350, 'imperial');
// Returns 1128.74 (lbs)

calculateNeededBodyWeight

var femaleBodyWeight = calculateNeededBodyWeight('f', 300, 350);
// Returns 56.6 (kg)

var maleBodyWeight = calculateNeededBodyWeight('m', 600, 350);
// Returns 113.2 (kg)

var femaleImperialBodyWeight = calculateNeededBodyWeight('f', 690, 660, 'imperial');
// Returns 131.62 (lbs)

var maleImperialBodyWeight = calculateNeededBodyWeight('m', 1128, 350, 'imperial');
// Returns 175.70 (lbs)

Tests

npm test

Package Sidebar

Install

npm i wilks-calculator

Weekly Downloads

2

Version

1.2.4

License

MIT

Unpacked Size

20.5 kB

Total Files

6

Last publish

Collaborators

  • evelijn
  • cavemobster