Template:Annualized rate/doc

From Wikipedia, the free encyclopedia

Usage[edit]

Syntax
{{Annualized rate|n}} (If an event has occurred n times so far this year, and continues happening at the same rate, how many times will it occur in the year overall?)
{{Annualized rate|n|year}} (Allows specification of a year in the syntax, so that once the year has passed, that same value is still returned. This version is recommended.)
{{subst:Annualized rate|n}} (substitute version of the first use)
{{subst:Annualized rate|n|year}} (substitute version of the second use)
Examples
  • {{Annualized rate}}: 0 (returns zero; use a parameter.)
  • {{Annualized rate|50}}: 117 (assumes current year if none specified.)
  • {{Annualized rate|50|2024}}: 117 (Putting in the current year helps stabilize the number for once this year is over.)
  • {{Annualized rate|180|2014}}: 180 (2014 has already passed, so the number entered is returned as the number for the whole year.)

This template accounts for leap years.

It assumes that the number passed as the first parameter is the count for the year up until the end of the current day.