Sha256: 65258848a7b0c1e90740cdfd8235c478c92ac1a434b19255c38abd2544abed05

Contents?: true

Size: 1.01 KB

Versions: 29

Compression:

Stored size: 1.01 KB

Contents

#
# = bio/shell/plugin/keggdas.rb - plugin for KEGG DAS
#
# Copyright::   Copyright (C) 2006
#               Toshiaki Katayama <k@bioruby.org>
# License::     The Ruby License
#
# $Id: das.rb,v 1.3 2007/04/05 23:35:41 trevor Exp $
#

module Bio

  class DAS
    def list_sequences
      result = ""
      self.get_dsn.each do |dsn|
        src = dsn.source_id
        self.get_entry_points(src).each do |ep|
          data = [src, ep.entry_id, ep.start.to_i, ep.stop.to_i, "# #{ep.description}"].join("\t") + "\n"
          puts data
          result += data
        end
      end
      return result
    end
  end

end

module Bio::Shell

  private

  # http://www.biodas.org/
  # http://www.dasregistry.org/

  def das(url = nil)
    if url
      @das = Bio::DAS.new(url)
    else
      @das ||= keggdas
    end
  end

  def keggdas(url = "http://das.hgc.jp/cgi-bin/")
    das(url)
  end

  def ensembl(url = "http://das.ensembl.org/")
    das(url)
  end

  def wormbase(url = "http://www.wormbase.org/db/")
    das(url)
  end

end

Version data entries

29 entries across 29 versions & 6 rubygems

Version Path
bio-shell-1.0.1 lib/bio/shell/plugin/das.rb
bio-shell-1.0.0 lib/bio/shell/plugin/das.rb
bio-1.5.2 lib/bio/shell/plugin/das.rb
bio-shell-0.0.0 lib/bio/shell/plugin/das.rb
bio-1.5.1 lib/bio/shell/plugin/das.rb
bio-1.5.0 lib/bio/shell/plugin/das.rb
bioruby-bio-1.2.9.9001 lib/bio/shell/plugin/das.rb
bioruby-bio-1.2.9.9501 lib/bio/shell/plugin/das.rb
bioruby-bio-1.3.0.5000 lib/bio/shell/plugin/das.rb
bioruby-bio-1.3.0.9901 lib/bio/shell/plugin/das.rb
bioruby-bio-1.3.0 lib/bio/shell/plugin/das.rb
bioruby-bio-1.3.1.5000 lib/bio/shell/plugin/das.rb
jandot-bio-1.2.1 lib/bio/shell/plugin/das.rb
ngoto-bio-1.2.9.9001 lib/bio/shell/plugin/das.rb
ngoto-bio-1.2.9.9501 lib/bio/shell/plugin/das.rb
ngoto-bio-1.3.0.5000 lib/bio/shell/plugin/das.rb
ngoto-bio-1.3.0 lib/bio/shell/plugin/das.rb
ngoto-bio-1.3.1.5000 lib/bio/shell/plugin/das.rb
wwood-bioruby-1.2.11 lib/bio/shell/plugin/das.rb
bio-1.4.3.0001 lib/bio/shell/plugin/das.rb