Jump to content

Module:Taxobox ranks/doc

From Wikipedia, the free encyclopedia

Module:Taxobox ranks (talk · edit · hist · links · doc · sandbox · testcases)

This module provides support to the automated taxobox system – templates such as {{Automatic taxobox}} or {{Speciesbox}}. Part of it also supports manual taxoboxes.

It defines:

  • The rank names that are acceptable and the way they are displayed in English.
  • For a subset of the rank names, it defines arbitrary numerical values that are used to check the consistent ordering of ranks in a taxonomic hierarchy.

It is thus part of the configuration of taxoboxes and taxonomy templates.

To add a new rank

[edit]

To add a new rank, edit the table that defines the local variable ranks in this module. The rank name should be in Latin, where a Latin version exists, and should be all lower-case. The equivalent English name should be capitalised. 'Special cases' have italicized English names. The complete table can be seen at Module:Taxobox ranks/testcases#Anglicised rank names.

Some ranks should always be checked for consistent rank ordering in a taxonomic hierarchy. For example, a genus must not occur above a family, and a family must not occur above an order. If the new rank is one that should always be checked in this way, then edit the table that defines the local variable rankValTable in this module. Use the table at Module:Taxobox ranks/testcases#Rank values to decide on a numerical value to be assigned to the rank to ensure correct ordering.

Usage

[edit]

Functions angliciseRank and lookupRankVal are used in the automated taxobox system to access the two tables defined in this module. {{Anglicise rank}} provides a template interface to angliciseRank. These functions are not intended for use outside the automated taxobox system.

A table containing all the ranks defined in the module can be displayed via {{#invoke:Taxobox ranks|showRanks}}.

A table containing all the rank values defined in the module can be displayed via {{#invoke:Taxobox ranks|showRankTable}}.

See also

[edit]

Further rank configuration for the automated taxobox system includes:

  • {{Principal rank}} – defines the Linnaean principal ranks that are shown by default in automated taxoboxes
  • {{Is italic taxon}} – defines which ranks cause taxon names to be italicized in automated taxoboxes