Skip to contents

Cleanup the title node from a KEGG igraph object

Usage

cleanup_title_node(g)

Arguments

g

The igraph object

Value

An igraph object, without the node originally kept as "TITLE:..."

Details

Strips away the node starting with the TITLE: label. In some situations, that node might not be too heavily needed...

Examples

graph <- create_kegg_graph(pathway_id = "hsa04110")
#> adding rname 'https://rest.kegg.jp/get/hsa04110/kgml'
#> 
#> adding rname 'https://rest.kegg.jp/list/compound'
#> 
#> adding rname 'https://rest.kegg.jp/list/glycan'
#> 
#> adding rname 'https://rest.kegg.jp/list/ko'
#> 
#> adding rname 'https://rest.kegg.jp/list/enzyme'
#> 
#> adding rname 'https://rest.kegg.jp/list/reaction'
#> 
graph_notitlenode <- cleanup_title_node(graph)
graph_notitlenode
#> IGRAPH 523a275 DN-B 133 119 -- 
#> + attr: title (g/c), type (g/c), name (v/c), type (v/c), link (v/c),
#> | reaction (v/c), reaction_link (v/c), reaction_label (v/c),
#> | graphics_name (v/c), node_name (v/c), KEGG (v/c), components (v/c),
#> | line_id (v/c), coords (v/c), graphics_type (v/c), point_index (v/n),
#> | de_value (v/n), de_text (v/c), de_source (v/c), de_name (v/c),
#> | ids_for_mapping (v/c), label (v/c), x (v/n), y (v/n), width (v/n),
#> | height (v/n), source (v/c), fgcolor (v/c), bgcolor (v/c), group
#> | (v/c), vertex.color (v/c), size (v/n), fixed (v/l), shape (v/c), type
#> | (e/c), relation_type (e/c), relation_subtype_name (e/c),
#> | relation_subtype_value (e/c), reaction_alt_name_substrate (e/c),
#> | reaction_alt_name_product (e/c), reaction_id (e/c), reaction_name
#> | (e/c), reaction_type (e/c), reaction_from_name (e/c),
#> | reaction_to_name (e/c), point_index (e/n), directed (e/l), color
#> | (e/c), width (e/n), value (e/n), label (e/c), lty (e/n), arrow.mode
#> | (e/c), dashes (e/l), title (e/c), font.face (e/c), borderWidth (e/n),
#> | borderWidthSelected (e/n), from (e/c), to (e/c)
#> + edges from 523a275 (vertex names):

render_kegg_graph(graph_notitlenode)