rxn.utilities.regex.optional

rxn.utilities.regex.optional(initial_regex, capture_group=False)[source]

Creates the regex string to make a group optional

Parameters
  • initial_regex (str) –

  • capture_group (bool, default: False) –

Return type

str