JavaScript calculators can perform whatever calculations you like as long as you know the appropriate formulae. Here's a JavaScript calculator for those with health and diet web sites. Given a couple of basic measurements this calculator uses a formula worked out by the US Navy to estimate the percentage of body fat.
Body Fat Calculator
Body Fat Calculator

For some reason some poeple are posting comments here about other copies of the calculator elsewhere that they claim are better. Since the calculation done is identical regardless of which site it is done on (or it isn’t BMI) and since this is a script you can copy to add a calculator to your own site there is no “better” option.
great work stephen