linkNames retrieves the corresponding names for a set of ids and
vice versa. It can be used to link feature names to ids that can be directly
passed to weavePath and weaveComplex.
linkNames(graph, ...)
# S4 method for class 'igraph'
linkNames(graph, x, ids = NULL, names = NULL, verbose = TRUE)An igraph object.
Unused.
Character scalar. A feature type present as a node in
graph.
Character vector. A set of ids to link to their
corresponding names. (Default: NULL)
Character vector. A set of names to link to their
corresponding ids. (Default: NULL)
Logical scalar. Should messages be printed in the
console. (Default: TRUE)
A LinkMap with ids and names in the first
and second column, respectively.
# Retrieve resource graph
graph <- ariadne()
# Fetch names for all Gut Metabolic modules
linkNames(graph, "gmm")
#> gmm gmm.name
#> 1 MF0001 arabinoxylan degradation
#> 2 MF0002 fructan degradation
#> 3 MF0003 pectin degradation I
#> 4 MF0004 pectine degradation II
#> 5 MF0005 starch degradation
#> 6 MF0006 lactose degradation
#> 7 MF0007 lactose and galactose degradation
#> 8 MF0008 maltose degradation
#> 9 MF0009 melibiose degradation
#> 10 MF0010 sucrose degradation I
#> 11 MF0011 sucrose degradation II
#> 12 MF0012 trehalose degradation
#> 13 MF0013 allose degradation
#> 14 MF0014 arabinose degradation
#> 15 MF0015 fructose degradation
#> 16 MF0016 fucose degradation
#> 17 MF0017 galactose degradation
#> 18 MF0018 mannose degradation
#> 19 MF0019 rhamnose degradation
#> 20 MF0020 ribose degradation
#> 21 MF0021 xylose degradation
#> 22 MF0022 galacturonate degradation I
#> 23 MF0023 galacturonate degradation II
#> 24 MF0024 phenylalanine degradation
#> 25 MF0025 tryptophan degradation
#> 26 MF0026 tyrosine degradation I
#> 27 MF0027 tyrosine degradation II
#> 28 MF0028 aspartate degradation I
#> 29 MF0029 aspartate degradation II
#> 30 MF0030 glutamate degradation I
#> 31 MF0031 glutamate degradation II
#> 32 MF0032 glutamate degradation III
#> 33 MF0033 alanine degradation I
#> 34 MF0034 alanine degradation II
#> 35 MF0035 glycine degradation
#> 36 MF0036 isoleucine degradation
#> 37 MF0037 leucine degradation
#> 38 MF0038 methionine degradation I
#> 39 MF0039 methionine degradation II
#> 40 MF0040 proline degradation
#> 41 MF0041 valine degradation I
#> 42 MF0042 asparagine degradation
#> 43 MF0043 cysteine biosynthesis/homocysteine degradation
#> 44 MF0044 cysteine degradation I
#> 45 MF0045 cysteine degradation II
#> 46 MF0046 glutamine degradation I
#> 47 MF0047 glutamine degradation II
#> 48 MF0048 serine degradation
#> 49 MF0049 threonine degradation I
#> 50 MF0050 threonine degradation II
#> 51 MF0051 arginine degradation I
#> 52 MF0052 arginine degradation II
#> 53 MF0053 arginine degradation III
#> 54 MF0054 arginine degradation IV
#> 55 MF0055 arginine degradation V
#> 56 MF0056 histidine degradation
#> 57 MF0057 lysine degradation I
#> 58 MF0058 lysine degradation II
#> 59 MF0059 anaerobic fatty acid beta-oxidation
#> 60 MF0060 glycerol degradation I
#> 61 MF0061 glycerol degradation II
#> 62 MF0062 glycerol degradation III
#> 63 MF0063 glyoxylate bypass
#> 64 MF0064 triacylglycerol degradation
#> 65 MF0065 Bifidobacterium shunt
#> 66 MF0066 Entner-Doudoroff pathway
#> 67 MF0067 glycolysis (preparatory phase)
#> 68 MF0068 glycolysis (pay-off phase)
#> 69 MF0069 NADH:ferredoxin oxidoreductase
#> 70 MF0070 pentose phosphate pathway (oxidative phase)
#> 71 MF0071 pentose phosphate pathway (non-oxidative branch)
#> 72 MF0072 pyruvate dehydrogenase complex
#> 73 MF0073 pyruvate:ferredoxin oxidoreductase
#> 74 MF0074 pyruvate:formate lyase
#> 75 MF0075 acetate to acetyl-CoA
#> 76 MF0076 4-aminobutyrate degradation
#> 77 MF0077 formate conversion
#> 78 MF0078 lactaldehyde degradation
#> 79 MF0079 lactate consumption I
#> 80 MF0080 lactate consumption II
#> 81 MF0081 methanol conversion
#> 82 MF0082 putrescine degradation
#> 83 MF0083 succinate consumption
#> 84 MF0084 succinate conversion to propionate
#> 85 MF0085 urea degradation
#> 86 MF0086 acetyl-CoA to acetate
#> 87 MF0087 acetyl-CoA to crotonyl-CoA
#> 88 MF0088 butyrate production I
#> 89 MF0089 butyrate production II
#> 90 MF0090 ethanol production I
#> 91 MF0091 ethanol production II
#> 92 MF0092 lactate production
#> 93 MF0093 propionate production I
#> 94 MF0094 propionate production II
#> 95 MF0095 propionate production III
#> 96 MF0096 succinate production
#> 97 MF0097 homoacetogenesis
#> 98 MF0098 hydrogen metabolism
#> 99 MF0099 methanogenesis - methyl-coM
#> 100 MF0100 methanogenesis from carbon dioxide
#> 101 MF0101 nitrate reduction (dissimilatory)
#> 102 MF0102 sulfate reduction (dissimilatory)
#> 103 MF0103 mucin degradation
# Fetch names for a set of KO ids
linkNames(graph, "ko", ids = c("K00001", "K00844", "K03455"))
#> ko ko.name
#> 1 K00001 alcohol dehydrogenase [EC:1.1.1.1]
#> 2 K00844 hexokinase [EC:2.7.1.1]
#> 3 K03455 K+:H+ antiporter
# Fetch names for a set of EC names
linkNames(graph, "ec", names = c("alcohol dehydrogenase", "alditol oxidase"))
#> ec ec.name
#> 1 1.1.1.1 alcohol dehydrogenase
#> 2 1.1.3.41 alditol oxidase