Regex Extract

RegexExtract extracts and adds one or more new fields to the data by using a regular expression.


regex Required
A valid JavaScript regular expression with at least one group. For example: "^Sample(\\d+)$".
Read more at:
field Required
The source field
as Required
The new field or an array of fields where the extracted values are written.
Do not complain about invalid input. Just skip it and leave the new fields undefined on the affected datum.
Default: false


Given the following data:

Gene Genome Location
AKT1 14:104770341-104792643

... and configuration:

  "type": "regexExtract",
  "field": "Genome Location",
  "regex": "^(X|Y|\\d+):(\\d+)-(\\d+)$",
  "as": ["Chrom", "Start", "End"]

Three new fields are added to the data:

Gene Genome Location Chrom Start End
AKT1 14:104770341-104792643 14 104770341 104792643