Skip to content

Main content

Pharmacogene Diplotype Order Canonicalizer Tool

Order simple star alleles numerically while preserving suballele spellings.

Loading tool…

Description

Order simple star alleles numerically while preserving suballele spellings.

Pharmacogenomic records distinguish allele labels, copy counts, reference-sequence versions, coordinate systems, and evidence about chromosome phase. A balanced count or matching token can check a record without establishing the underlying genotype. Supplied activity values and interpretation rules remain separate from a current gene-specific clinical guideline.

Order simple star alleles numerically while preserving suballele spellings.

When to use this tool

Use Pharmacogene Diplotype Order Canonicalizer when you need this specific allele-token, reference-coordinate, copy-budget, or source-support check.

How to use the tool and how it works

  1. Enter first, second. Use the units and conventions below.
  2. Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
  3. Read first, second, swapped. Inspect swapped before interpreting the associated values.

Parse each allele as * followed by a positive integer and an optional decimal suballele suffix. Compare the major numbers using exact integers, then numeric suballele values, treating an absent suffix as -1. Return the original strings ordered by those keys and swapped.1

Input fieldMeaning and unitsAccepted input
firstFirst supported star-allele label; output is one original input string.Required. Text; maximum UTF-16 length 8192.
secondSecond supported star-allele label; output is one original input string.Required. Text; maximum UTF-16 length 8192.
Output fieldInterpretationReturned shape
firstFirst supported star-allele label; output is one original input string.Required. Text; maximum UTF-16 length 8192.
secondSecond supported star-allele label; output is one original input string.Required. Text; maximum UTF-16 length 8192.
swappedSwappedRequired. Boolean.
json
{
  "input": {
    "first": "*10",
    "second": "*2"
  },
  "output": {
    "first": "*2",
    "second": "*10",
    "swapped": true
  }
}

Limitations and assumptions

  • Leading zeros in a suffix are preserved and numerically equal suffixes retain input order. No gene context, nomenclature lookup, phase, or clinical equivalence is established.
  • Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.

Alternative or Complementary methods

Use a current gene-specific nomenclature and a validated interpretation process when allele identity, phase, function, or clinical decisions matter. Verify source versions and reference coordinates before combining records.

References

  1. Calculation and input contract: pharmacogenomics/pharmacogene-diplotype-order-canonicalizer — tool.io

Similar or alternative tools