Difference between revisions of "Template:BMI/doc"

From blackwiki
Jump to navigation Jump to search
imported>Plastikspork
(→‎Examples: Update)
imported>Lightmouse
(Mostly units)
Line 7: Line 7:
  
 
The weight can be specified using either of the following units:
 
The weight can be specified using either of the following units:
* <code>kg=</code> [[kilogram]]s
+
* <code>kg=</code> kilograms
* <code>lb=</code> [[pound (mass)|pound]]s
+
* <code>lb=</code> pounds
  
 
The height can be specified using one (or more) of the following units:
 
The height can be specified using one (or more) of the following units:
* <code>{{0}}m=</code> [[metre]]s
+
* <code>{{0}}m=</code> metres
* <code>cm=</code> [[centimetre]]s
+
* <code>cm=</code> centimetres
* <code>ft=</code> [[foot (length)|feet]]
+
* <code>ft=</code> feet
* <code>in=</code> [[inch]]es
+
* <code>in=</code> inches
  
 
=== Examples ===
 
=== Examples ===

Revision as of 22:15, 10 August 2011

This template calculates a person's body mass index using his or her height and weight.

Usage

The person's height and weight must both be specified.

The weight can be specified using either of the following units:

  • kg= kilograms
  • lb= pounds

The height can be specified using one (or more) of the following units:

  • 0m= metres
  • cm= centimetres
  • ft= feet
  • in= inches

Examples

Code Result
{{BMI|m = 1.82|kg = 56}} 16.9
{{BMI|cm = 182|kg = 81}} 24.5
{{BMI|ft = 6|lb = 200}} 27.1
{{BMI|in = 72|lb = 250}} 33.9
{{BMI|ft = 6|in = 1|lb = 275}} 36.3
{{BMI|m = 1.62|lb = 250}} 43.2

Optional table coloring

Code Result
{{BMI|m = 1.82|kg = 56|color=y}} 16.9
{{BMI|cm = 182|kg = 81|color=y}} 24.5
{{BMI|ft = 6|lb = 200|color=y}} 27.1
{{BMI|in = 72|lb = 250|color=y}} 33.9
{{BMI|ft = 6|in = 1|lb = 275|color=y}} 36.3
{{BMI|m = 1.62|lb = 250|color=y}} 43.2

See also