Module: NCIReactomePathway

Extended by:
Entity
Defined in:
lib/rbbt/sources/NCI.rb

Class Method Summary collapse

Class Method Details

.filter(query, field = nil, options = nil, entity = nil) ⇒ Object



56
57
58
59
60
61
62
# File 'lib/rbbt/sources/NCI.rb', line 56

def self.filter(query, field = nil, options = nil, entity = nil)
  return true if query == entity

  return true if self.setup(entity.dup, options.merge(:format => field)).name.index query

  false
end

.gene_indexObject



52
53
54
# File 'lib/rbbt/sources/NCI.rb', line 52

def self.gene_index
  @gene_index ||= NCI.reactome_pathways.tsv(:persist => true, :key_field => "NCI Reactome Pathway ID", :fields => ["UniProt/SwissProt Accession"], :type => :flat, :merge => true)
end

.name_indexObject



48
49
50
# File 'lib/rbbt/sources/NCI.rb', line 48

def self.name_index
  @name_index ||= NCI.reactome_pathways.tsv(:persist => true, :key_field => "NCI Reactome Pathway ID", :fields => ["Pathway Name"], :type => :single)
end