class Bio::KEGG::PATHWAY

Description

Bio::KEGG::PATHWAY is a parser class for the KEGG PATHWAY database entry.

References

Constants

DELIMITER
TAGSIZE

Public Class Methods

new(entry) click to toggle source

Creates a new Bio::KEGG::PATHWAY object.


Arguments:

  • (required) entry: (String) single entry as a string

Returns

Bio::KEGG::PATHWAY object

Calls superclass method Bio::NCBIDB::new
   # File lib/bio/db/kegg/pathway.rb
76 def initialize(entry)
77   super(entry, TAGSIZE)
78 end

Public Instance Methods

compounds()
Alias for: compounds_as_hash
compounds_as_hash() click to toggle source

Compounds described in the COMPOUND lines.


Returns

Hash of compound ID and its definition

    # File lib/bio/db/kegg/pathway.rb
205 def compounds_as_hash
206   unless (defined? @compounds_as_hash) && @compounds_as_hash
207     @compounds_as_hash = strings_as_hash(compounds_as_strings)
208   end
209   @compounds_as_hash
210 end
Also aliased as: compounds
compounds_as_strings() click to toggle source

Compounds described in the COMPOUND lines.


Returns

Array containing String

    # File lib/bio/db/kegg/pathway.rb
198 def compounds_as_strings
199   lines_fetch('COMPOUND')
200 end
definition()
Alias for: description
description() click to toggle source

Description of the pathway, described in the DESCRIPTION line.


Returns

String

   # File lib/bio/db/kegg/pathway.rb
97 def description
98   field_fetch('DESCRIPTION')
99 end
Also aliased as: definition
diseases()
Alias for: diseases_as_hash
diseases_as_hash() click to toggle source

Returns a Hash of the disease ID and its definition

   # File lib/bio/db/kegg/pathway.rb
47 def diseases_as_hash; super; end
Also aliased as: diseases
diseases_as_strings() click to toggle source

Disease described in the DISEASE lines.


Returns

Array containing String

    # File lib/bio/db/kegg/pathway.rb
126 def diseases_as_strings
127   lines_fetch('DISEASE')
128 end
entry_id() click to toggle source

Return the ID of the pathway, described in the ENTRY line.


Returns

String

   # File lib/bio/db/kegg/pathway.rb
83 def entry_id
84   field_fetch('ENTRY')[/\S+/]
85 end
enzymes()
Alias for: enzymes_as_strings
enzymes_as_strings() click to toggle source

Enzymes described in the ENZYME lines.


Returns

Array containing String

    # File lib/bio/db/kegg/pathway.rb
172 def enzymes_as_strings
173   lines_fetch('ENZYME')
174 end
Also aliased as: enzymes
genes()
Alias for: genes_as_hash
genes_as_hash() click to toggle source

Genes described in the GENE lines.


Returns

Hash of gene ID and its definition

    # File lib/bio/db/kegg/pathway.rb
161 def genes_as_hash
162   unless (defined? @genes_as_hash) && @genes_as_hash
163     @genes_as_hash = strings_as_hash(genes_as_strings)
164   end
165   @genes_as_hash
166 end
Also aliased as: genes
genes_as_strings() click to toggle source

Genes described in the GENE lines.


Returns

Array containing String

    # File lib/bio/db/kegg/pathway.rb
154 def genes_as_strings
155   lines_fetch('GENE')
156 end
keggclass() click to toggle source

Return the name of the KEGG class, described in the CLASS line.


Returns

String

    # File lib/bio/db/kegg/pathway.rb
105 def keggclass
106   field_fetch('CLASS')
107 end
ko_pathway() click to toggle source

KO pathway described in the KO_PATHWAY line.


Returns

String

    # File lib/bio/db/kegg/pathway.rb
240 def ko_pathway
241   field_fetch('KO_PATHWAY')
242 end
modules()
Alias for: modules_as_hash
modules_as_hash() click to toggle source

Returns MODULE field as a Hash. Each key of the hash is KEGG MODULE ID, and each value is the name of the Pathway Module.


Returns

Hash

   # File lib/bio/db/kegg/pathway.rb
63 def modules_as_hash; super; end
Also aliased as: modules
modules_as_strings() click to toggle source

Returns MODULE field of the entry.


Returns

Array containing String objects

    # File lib/bio/db/kegg/pathway.rb
119 def modules_as_strings
120   lines_fetch('MODULE')
121 end
name() click to toggle source

Name of the pathway, described in the NAME line.


Returns

String

   # File lib/bio/db/kegg/pathway.rb
90 def name
91   field_fetch('NAME')
92 end
organism() click to toggle source

Organism described in the ORGANISM line.


Returns

String

    # File lib/bio/db/kegg/pathway.rb
147 def organism
148   field_fetch('ORGANISM')
149 end
orthologs()
Alias for: orthologs_as_hash
orthologs_as_hash() click to toggle source

Returns a Hash of the orthology ID and definition in ORTHOLOGY field.

   # File lib/bio/db/kegg/pathway.rb
42 def orthologs_as_hash; super; end
Also aliased as: orthologs
orthologs_as_strings() click to toggle source

Orthologs described in the ORTHOLOGY lines.


Returns

Array containing String

    # File lib/bio/db/kegg/pathway.rb
140 def orthologs_as_strings
141   lines_fetch('ORTHOLOGY')
142 end
pathways()
Alias for: pathways_as_hash
pathways_as_hash() click to toggle source

Returns a Hash of the pathway ID and name in PATHWAY field.

   # File lib/bio/db/kegg/pathway.rb
37 def pathways_as_hash; super; end
Also aliased as: pathways
pathways_as_strings() click to toggle source

Pathways described in the PATHWAY_MAP lines.


Returns

Array containing String

    # File lib/bio/db/kegg/pathway.rb
112 def pathways_as_strings
113   lines_fetch('PATHWAY_MAP')
114 end
reactions()
Alias for: reactions_as_hash
reactions_as_hash() click to toggle source

Reactions described in the REACTION lines.


Returns

Hash of reaction ID and its definition

    # File lib/bio/db/kegg/pathway.rb
187 def reactions_as_hash
188   unless (defined? @reactions_as_hash) && @reactions_as_hash
189     @reactions_as_hash = strings_as_hash(reactions_as_strings)
190   end
191   @reactions_as_hash
192 end
Also aliased as: reactions
reactions_as_strings() click to toggle source

Reactions described in the REACTION lines.


Returns

Array containing String

    # File lib/bio/db/kegg/pathway.rb
180 def reactions_as_strings
181   lines_fetch('REACTION')
182 end
references() click to toggle source

REFERENCE – Returns contents of the REFERENCE records as an Array of Bio::Reference objects.


Returns

an Array containing Bio::Reference objects

   # File lib/bio/db/kegg/pathway.rb
55 def references; super; end
rel_pathways()
rel_pathways_as_hash() click to toggle source

Returns REL_PATHWAY field as a Hash. Each key of the hash is Pathway ID, and each value is the name of the pathway.


Returns

Hash

    # File lib/bio/db/kegg/pathway.rb
224 def rel_pathways_as_hash
225   unless defined? @rel_pathways_as_hash then
226     hash = {}
227     rel_pathways_as_strings.each do |line|
228       entry_id, name = line.split(/\s+/, 2)
229       hash[entry_id] = name
230     end
231     @rel_pathways_as_hash = hash
232   end
233   @rel_pathways_as_hash
234 end
Also aliased as: rel_pathways
rel_pathways_as_strings() click to toggle source

Returns REL_PATHWAY field of the entry.


Returns

Array containing String objects

    # File lib/bio/db/kegg/pathway.rb
216 def rel_pathways_as_strings
217   lines_fetch('REL_PATHWAY')
218 end