Skip to contents

Parse IUPAC-extended-style structure characters into glycan graphs. For more information about IUPAC-extended format, see https://doi.org/10.1351/pac199668101919.

Usage

parse_iupac_extended(x)

Arguments

x

A character vector of IUPAC-extended strings.

Value

A glycan graph if x is a single character, or a list of glycan graphs if x is a character vector.

Examples

iupac <- "β-D-Galp-(1→3)[β-D-Galp-(1→4)-β-D-GlcpNAc-(1→6)]-α-D-GalpNAc-(1→"
parse_iupac_extended(iupac)
#> <glycan_structure[1]>
#> [1] Gal(b1-4)GlcNAc(b1-6)[Gal(b1-3)]GalNAc(a1-
#> # Unique structures: 1