package biocaml

  1. Overview
  2. Docs
The OCaml Bioinformatics Library

Install

Dune Dependency

Authors

Maintainers

Sources

biocaml-0.11.2.tbz
sha256=fae219e66db06f81f3fd7d9e44717ccf2d6d85701adb12004ab4ae6d3359dd2d
sha512=f6abd60dac2e02777be81ce3b5acdc0db23b3fa06731f5b2d0b32e6ecc9305fe64f407bbd95a3a9488b14d0a7ac7c41c73a7e18c329a8f18febfc8fd50eccbc6

doc/biocaml.unix/Biocaml_unix/Chr/index.html

Module Biocaml_unix.ChrSource

Chromosome names. A chromosome name, as defined by this module, consists of two parts. An optional prefix "chr" (case-insensitive), followed by a suffix identifying the chromosome. The possible suffixes (case-insensitive) are:

  • "X" representing the maternal chromosome
  • "Y" representing the paternal chromosome
  • "M", "Mt", or "MtDNA" representing mitochondrial DNA
  • "N" where N is a positive number in either arabic or roman numeral form

Some suffixes have ambiguous interpretations, e.g. "X" could be a Roman numeral or the maternal chromosome. Preference is given to the non-numeric interpretation. Thus "chrX" is treated as the maternal chromosome, not chromosome 10. Strings not in the above form are left unaltered by the functions of this module.

Functions for converting to an Arabic or Roman format are provided. The benefit is that these functions convert to a canonical form, and thus the resulting strings can be compared reliably. For example, to_arabic "Chr4" and to_arabic "IV" both return "4". The Arabic format is recommended over the Roman form because the Roman form is incomplete; e.g. it cannot represent chromosome number 10 because there would be an ambiguity with the maternal chromosome "chrX".

Sourcemodule Error : sig ... end
Sourceexception Error of Error.t
Sourceval to_arabic : string -> string

to_arabic s returns the canonical Arabic representation of s.

Sourceval to_roman : string -> (string, Error.t) Core.Result.t

to_roman s returns the canonical Roman representation of s.

Sourceval to_roman_exn : string -> string
OCaml

Innovation. Community. Security.