sequenceserver-beta 0.8.7.beta1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/Gemfile +3 -0
- data/LICENSE.Apache.txt +176 -0
- data/LICENSE.txt +69 -0
- data/README.txt +5 -0
- data/bin/sequenceserver +82 -0
- data/config.ru +6 -0
- data/example.config.yml +39 -0
- data/lib/profile_code.rb +217 -0
- data/lib/sequenceserver.rb +527 -0
- data/lib/sequenceserver/blast.rb +92 -0
- data/lib/sequenceserver/customisation.rb +60 -0
- data/lib/sequenceserver/database.rb +29 -0
- data/lib/sequenceserver/database_formatter.rb +190 -0
- data/lib/sequenceserver/helpers.rb +136 -0
- data/lib/sequenceserver/sequencehelpers.rb +93 -0
- data/lib/sequenceserver/sinatralikeloggerformatter.rb +12 -0
- data/lib/sequenceserver/version.rb +9 -0
- data/public/css/beige.css.css +254 -0
- data/public/css/bootstrap.dropdown.css +29 -0
- data/public/css/bootstrap.icons.css +155 -0
- data/public/css/bootstrap.min.css +415 -0
- data/public/css/bootstrap.modal.css +28 -0
- data/public/css/custom.css +232 -0
- data/public/img/glyphicons-halflings-white.png +0 -0
- data/public/img/glyphicons-halflings.png +0 -0
- data/public/js/bootstrap.dropdown.js +92 -0
- data/public/js/bootstrap.modal.js +7 -0
- data/public/js/bootstrap.transition.js +7 -0
- data/public/js/jquery-scrollspy.js +98 -0
- data/public/js/jquery-ui.js +14987 -0
- data/public/js/jquery.activity.js +10 -0
- data/public/js/jquery.enablePlaceholder.min.js +10 -0
- data/public/js/jquery.js +5 -0
- data/public/js/sequenceserver.blast.js +208 -0
- data/public/js/sequenceserver.js +304 -0
- data/public/js/store.min.js +2 -0
- data/sequenceserver.gemspec +49 -0
- data/tests/database/nucleotide/Sinvicta2-2-3.cdna.subset.fasta +5486 -0
- data/tests/database/nucleotide/Sinvicta2-2-3.cdna.subset.fasta.nhr +0 -0
- data/tests/database/nucleotide/Sinvicta2-2-3.cdna.subset.fasta.nin +0 -0
- data/tests/database/nucleotide/Sinvicta2-2-3.cdna.subset.fasta.nsq +0 -0
- data/tests/database/protein/Sinvicta2-2-3.prot.subset.fasta +6449 -0
- data/tests/database/protein/Sinvicta2-2-3.prot.subset.fasta.phr +0 -0
- data/tests/database/protein/Sinvicta2-2-3.prot.subset.fasta.pin +0 -0
- data/tests/database/protein/Sinvicta2-2-3.prot.subset.fasta.psq +0 -0
- data/tests/run +26 -0
- data/tests/test_sequencehelpers.rb +77 -0
- data/tests/test_sequenceserver_blast.rb +60 -0
- data/tests/test_ui.rb +104 -0
- data/tests/test_ui.rb~ +104 -0
- data/tests/ui.specs.todo +10 -0
- data/views/500.erb +22 -0
- data/views/_options.erb +144 -0
- data/views/search.erb +220 -0
- metadata +226 -0
Binary file
|
Binary file
|
Binary file
|
data/tests/run
ADDED
@@ -0,0 +1,26 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
# Usage:
|
3
|
+
#
|
4
|
+
# run all test suites
|
5
|
+
#
|
6
|
+
# $ tests/run
|
7
|
+
#
|
8
|
+
# run a particular test suite
|
9
|
+
#
|
10
|
+
# $ tests/run tests/test_sequencehelpers.rb
|
11
|
+
#
|
12
|
+
|
13
|
+
# script dir
|
14
|
+
dir = File.dirname(__FILE__)
|
15
|
+
|
16
|
+
# setup load path
|
17
|
+
require 'rubygems'
|
18
|
+
$LOAD_PATH.unshift(File.join(dir, '..', 'lib'))
|
19
|
+
|
20
|
+
# user specified or glob all?
|
21
|
+
files = ARGV.empty? ? Dir[File.join(dir, 'test_*.rb')] : ARGV
|
22
|
+
|
23
|
+
# run!
|
24
|
+
files.each do |file|
|
25
|
+
require File.expand_path(file)
|
26
|
+
end
|
@@ -0,0 +1,77 @@
|
|
1
|
+
require 'sequenceserver'
|
2
|
+
require 'sequenceserver/sequencehelpers'
|
3
|
+
require 'test/unit'
|
4
|
+
|
5
|
+
class Tester < Test::Unit::TestCase
|
6
|
+
include SequenceServer::SequenceHelpers
|
7
|
+
def test_guess_sequence_type_nucleotide
|
8
|
+
#must 'correctly detect nucleotide sequence, even when it includes crap' do
|
9
|
+
['AAAAAAAAAAAAAAAAAAAAAT',
|
10
|
+
' CAGATGCRRCAAAGCAAACGGCAA 34523453 652352',
|
11
|
+
'ACCNNNNNNXXXXCAUUUUUU',
|
12
|
+
"ACGT\n\t\t\nACCACGGACCACGAAAGCG" ].each do |seq|
|
13
|
+
assert_equal(:nucleotide, guess_sequence_type(seq), message="for #{seq}")
|
14
|
+
end
|
15
|
+
end
|
16
|
+
|
17
|
+
def test_guess_sequence_type_aminoacid
|
18
|
+
#must 'correctly detect aminoacid sequence, even when it includes a lot of crap' do
|
19
|
+
['ADSACGHKSJLFCVMGTL',
|
20
|
+
' 345 KSSYPHYSPPPPHS 345 23453 652352',
|
21
|
+
'GEYSNLNNNNNNXXXXSSSSSSSSSSSSSSSSSSSSSSS',
|
22
|
+
"EE\n\t\t\n \t\t\EEQRRQQSARTSRRQR" ].each do |seq|
|
23
|
+
assert_equal(:protein, guess_sequence_type(seq) , message="for #{seq}")
|
24
|
+
end
|
25
|
+
end
|
26
|
+
|
27
|
+
def test_guess_sequence_type_impossible
|
28
|
+
assert_equal(nil, guess_sequence_type('ACSFGT'), message='too little sequence')
|
29
|
+
end
|
30
|
+
|
31
|
+
## Tests for type_of_sequences (multi-fasta kind of thing the user would enter)
|
32
|
+
def test_type_of_sequences
|
33
|
+
aa_multifasta = ">SDFDSF\nACGTGSDLKJGNLDKSJFLSDKJFLSDKOIU\n>asdfas\nasfasdfffffffffffffffffffff\n>alksjflkasdj slakdjf\nasdfasdfasdfljaslkdjf"
|
34
|
+
aa_multifasta_including_short_seq_missing_lead = "ACGTGSDLKJGNLDKSJFLSDKJFLSDKOIU\n>asdfas\nasf\n>alksjflkasdj slakdjf\nasdfasdfasdfljaslkdjf"
|
35
|
+
aa_singlesequence = "ACGTGSDLKJGNLDKSJFLSDKJFLSDKOIU\n"
|
36
|
+
nt_multifasta = ">asdf\nAAAAAAAAAAAAAAAAAAAAT\n>sfaslkj\nCAGATGCRRCAAAGCAAACGGCAA\n>asssssjlkj\nACCCANNNNNNXXXXCAUUUUUU"
|
37
|
+
aa_nt_mix = ">alksjflkasdj slakdjf\nasdfasdfasdfljaslkdjf\n>ffffffassdf\nACGCNAGTGCCCCCCCCGANATGGGTGGTTXXXXXGGTG"
|
38
|
+
|
39
|
+
assert_equal(:protein, type_of_sequences(aa_multifasta), 'aa_multifasta')
|
40
|
+
assert_equal(:protein, type_of_sequences(aa_multifasta_including_short_seq_missing_lead ), 'aa_multifasta_short_seq_and_no_>')
|
41
|
+
assert_equal(:protein, type_of_sequences(aa_singlesequence), 'single AA sequence')
|
42
|
+
assert_equal(:nucleotide, type_of_sequences(nt_multifasta), 'nt_multifasta')
|
43
|
+
assert_raise(ArgumentError, 'mixed aa and nt should raise') { type_of_sequences(aa_nt_mix) }
|
44
|
+
end
|
45
|
+
|
46
|
+
def test_composition
|
47
|
+
expected_comp = {"a"=>2, "d"=>3, "f"=>7, "s"=>3, "A"=>1}
|
48
|
+
assert_equal(expected_comp, composition('asdfasdfffffAsdf'))
|
49
|
+
end
|
50
|
+
|
51
|
+
def test_construct_standard_sequence_hyperlink
|
52
|
+
assert_equal "/get_sequence/?id=one&db=abc def", construct_standard_sequence_hyperlink({:sequence_id => 'one', :databases => %w(abc def)})
|
53
|
+
assert_equal nil, construct_standard_sequence_hyperlink({:sequence_id => ' one', :databases => %w(abc def)})
|
54
|
+
assert_equal "/get_sequence/?id=MAL13P1.218&db=abc def", construct_standard_sequence_hyperlink({:sequence_id => 'lcl|MAL13P1.218', :databases => %w(abc def)})
|
55
|
+
end
|
56
|
+
end
|
57
|
+
|
58
|
+
class AppTester < Test::Unit::TestCase
|
59
|
+
def test_process_advanced_blast_options
|
60
|
+
app = SequenceServer::App.new!
|
61
|
+
|
62
|
+
assert_nothing_raised {app.validate_advanced_parameters('')}
|
63
|
+
assert_nothing_raised {app.validate_advanced_parameters('-word_size 5')}
|
64
|
+
assert_raise(ArgumentError, 'security advanced option parser'){app.validate_advanced_parameters('-word_size 5; rm -rf /')}
|
65
|
+
assert_raise(ArgumentError, 'conflicting advanced option'){app.validate_advanced_parameters('-db roar')}
|
66
|
+
end
|
67
|
+
end
|
68
|
+
|
69
|
+
class SystemHelpersTester < Test::Unit::TestCase
|
70
|
+
include SequenceServer::Helpers::SystemHelpers
|
71
|
+
|
72
|
+
def test_multipart_database_name?
|
73
|
+
assert_equal true, multipart_database_name?('/home/ben/pd.ben/sequenceserver/db/nr.00')
|
74
|
+
assert_equal false, multipart_database_name?('/home/ben/pd.ben/sequenceserver/db/nr')
|
75
|
+
assert_equal true, multipart_database_name?('/home/ben/pd.ben/sequenceserver/db/img3.5.finished.faa.01')
|
76
|
+
end
|
77
|
+
end
|
@@ -0,0 +1,60 @@
|
|
1
|
+
require 'sequenceserver'
|
2
|
+
require 'minitest/spec'
|
3
|
+
require 'minitest/autorun'
|
4
|
+
require 'rack/test'
|
5
|
+
|
6
|
+
ENV['RACK_ENV'] = 'test'
|
7
|
+
|
8
|
+
module SequenceServer
|
9
|
+
describe "App" do
|
10
|
+
include Rack::Test::Methods
|
11
|
+
|
12
|
+
def app
|
13
|
+
App
|
14
|
+
end
|
15
|
+
|
16
|
+
def setup
|
17
|
+
@params = {'method' => 'blastn', 'sequence' => 'AGCTAGCTAGCT', 'databases' => ['123']}
|
18
|
+
end
|
19
|
+
|
20
|
+
it 'returns Bad Request (400) if no blast method is provided' do
|
21
|
+
@params.delete('method')
|
22
|
+
post '/', @params
|
23
|
+
last_response.status.must_equal 400
|
24
|
+
end
|
25
|
+
|
26
|
+
it 'returns Bad Request (400) if no input sequence is provided' do
|
27
|
+
@params.delete('sequence')
|
28
|
+
post '/', @params
|
29
|
+
last_response.status.must_equal 400
|
30
|
+
end
|
31
|
+
|
32
|
+
it 'returns Bad Request (400) if no database id is provided' do
|
33
|
+
@params.delete('databases')
|
34
|
+
post '/', @params
|
35
|
+
last_response.status.must_equal 400
|
36
|
+
end
|
37
|
+
|
38
|
+
it 'returns Bad Request (400) if an empty database list is provided' do
|
39
|
+
@params['databases'].pop
|
40
|
+
|
41
|
+
# ensure the list of databases is empty
|
42
|
+
@params['databases'].length.must_equal 0
|
43
|
+
|
44
|
+
post '/', @params
|
45
|
+
last_response.status.must_equal 400
|
46
|
+
end
|
47
|
+
|
48
|
+
it 'returns Bad Request (400) if an incorrect blast method is supplied' do
|
49
|
+
@params['method'] = 'foo'
|
50
|
+
post '/', @params
|
51
|
+
last_response.status.must_equal 400
|
52
|
+
end
|
53
|
+
|
54
|
+
it 'returns Bad Request (400) if incorrect advanced params are supplied' do
|
55
|
+
@params['advanced'] = '-word_size 5; rm -rf /'
|
56
|
+
post '/', @params
|
57
|
+
last_response.status.must_equal 400
|
58
|
+
end
|
59
|
+
end
|
60
|
+
end
|
data/tests/test_ui.rb
ADDED
@@ -0,0 +1,104 @@
|
|
1
|
+
require 'rspec'
|
2
|
+
require 'watir-webdriver'
|
3
|
+
require 'headless'
|
4
|
+
|
5
|
+
# These shared examples should work for
|
6
|
+
shared_examples_for 'a browser' do
|
7
|
+
let(:seqserv_url){'http://localhost:4567'}
|
8
|
+
|
9
|
+
it 'should simply go the seqserv webpage' do
|
10
|
+
b.goto seqserv_url
|
11
|
+
b.url.gsub(/\/$/,'').should eq(seqserv_url)
|
12
|
+
b.ready_state.should eq('complete')
|
13
|
+
end
|
14
|
+
|
15
|
+
it 'should do a simple blastp' do
|
16
|
+
b.goto seqserv_url
|
17
|
+
|
18
|
+
# Nucleotide database should be available
|
19
|
+
b.checkbox(:value => 'ed4250adc44601256f6bbbd4ab5cc80c').enabled?.should eq(true)
|
20
|
+
|
21
|
+
# First up the blast button should be disabled
|
22
|
+
b.button(:id => 'method').text.should eq('BLAST')
|
23
|
+
b.button(:id => 'method').enabled?.should eq(false)
|
24
|
+
|
25
|
+
# Pick a protein blast database
|
26
|
+
b.checkbox(:value => 'b9a05001b93ca2587b447dacb9906f2a').set
|
27
|
+
b.checkbox(:value => 'b9a05001b93ca2587b447dacb9906f2a').checked?.should eq(true)
|
28
|
+
|
29
|
+
# nuc dbs now disabled
|
30
|
+
b.checkbox(:value => 'ed4250adc44601256f6bbbd4ab5cc80c').enabled?.should eq(false)
|
31
|
+
|
32
|
+
# The blast button should still be disabled
|
33
|
+
b.button(:id => 'method').text.should eq('BLAST')
|
34
|
+
b.button(:id => 'method').enabled?.should eq(false)
|
35
|
+
|
36
|
+
# Give a sequence we know should hit
|
37
|
+
b.textarea(:name => 'sequence').set 'YTLPPPPTKLYSAPISCRKNKTGHWMDDILSIKTGESCPVNNYLHSGFLA'
|
38
|
+
|
39
|
+
#blast butn now active
|
40
|
+
b.button(:id => 'method').text.should eq('BLASTP')
|
41
|
+
b.button(:id => 'method').enabled?.should eq(true)
|
42
|
+
|
43
|
+
# Run the blast
|
44
|
+
b.button(:id => 'method').click
|
45
|
+
|
46
|
+
while b.div(:id => 'result').text.include?('Waiting for BLAST to be run')
|
47
|
+
end
|
48
|
+
|
49
|
+
# blast should have worked
|
50
|
+
b.div(:id => 'result').text.include?('FASTA of 11 retrievable').should eq(true)
|
51
|
+
end
|
52
|
+
end
|
53
|
+
|
54
|
+
#####################################################################################
|
55
|
+
#+++++++++++ Below is admin code, hopefully not necessary to mess around with to test new UI specs
|
56
|
+
|
57
|
+
# NOT thread-safe, at least because of the interaction with headless
|
58
|
+
class BrowserAdmin
|
59
|
+
def self.setup_browser(type)
|
60
|
+
case type
|
61
|
+
when :firefox then
|
62
|
+
Watir::Browser.new :firefox
|
63
|
+
when :chrome then
|
64
|
+
Watir::Browser.new :chrome
|
65
|
+
when :headless_firefox then
|
66
|
+
@headless = Headless.new
|
67
|
+
@headless.start
|
68
|
+
Watir::Browser.new :firefox
|
69
|
+
when :headless_chrome then
|
70
|
+
@headless = Headless.new
|
71
|
+
@headless.start
|
72
|
+
Watir::Browser.new :chrome
|
73
|
+
else
|
74
|
+
raise "Unknown browser type asked for: #{type.inspect}"
|
75
|
+
end
|
76
|
+
end
|
77
|
+
|
78
|
+
def self.teardown_browser(browser)
|
79
|
+
browser.close
|
80
|
+
|
81
|
+
# Re-head again, but maybe this makes no difference
|
82
|
+
@headless.destroy unless @headless.nil?
|
83
|
+
@headless = nil
|
84
|
+
end
|
85
|
+
end
|
86
|
+
|
87
|
+
|
88
|
+
describe 'ui' do
|
89
|
+
[:firefox, :chrome, :headless_firefox, :headless_chrome].each do |bro|
|
90
|
+
context bro.to_s do
|
91
|
+
it_behaves_like 'a browser' do
|
92
|
+
browser = nil
|
93
|
+
before do
|
94
|
+
browser = BrowserAdmin.setup_browser bro
|
95
|
+
end
|
96
|
+
after do
|
97
|
+
BrowserAdmin.teardown_browser browser
|
98
|
+
end
|
99
|
+
let(:b){browser}
|
100
|
+
end
|
101
|
+
end
|
102
|
+
end
|
103
|
+
end
|
104
|
+
|
data/tests/test_ui.rb~
ADDED
@@ -0,0 +1,104 @@
|
|
1
|
+
require 'rspec'
|
2
|
+
require 'watir-webdriver'
|
3
|
+
require 'headless'
|
4
|
+
|
5
|
+
# These shared examples should work for
|
6
|
+
shared_examples_for 'a browser' do
|
7
|
+
let(:seqserv_url){'http://localhost:4567'}
|
8
|
+
|
9
|
+
it 'should simply go the seqserv webpage' do
|
10
|
+
b.goto seqserv_url
|
11
|
+
b.url.gsub(/\/$/,'').should eq(seqserv_url)
|
12
|
+
b.ready_state.should eq('complete')
|
13
|
+
end
|
14
|
+
|
15
|
+
it 'should do a simple blastp' do
|
16
|
+
b.goto seqserv_url
|
17
|
+
|
18
|
+
# Nucleotide database should be available
|
19
|
+
b.checkbox(:value => 'e205221dd32dc53ebfc9fb48cbdecd9e').enabled?.should eq(true)
|
20
|
+
|
21
|
+
# First up the blast button should be disabled
|
22
|
+
b.button(:id => 'method').text.should eq('BLAST')
|
23
|
+
b.button(:id => 'method').enabled?.should eq(false)
|
24
|
+
|
25
|
+
# Pick a protein blast database
|
26
|
+
b.checkbox(:value => '6669b1c88665158621afc06407ce88ea').set
|
27
|
+
b.checkbox(:value => '6669b1c88665158621afc06407ce88ea').checked?.should eq(true)
|
28
|
+
|
29
|
+
# nuc dbs now disabled
|
30
|
+
b.checkbox(:value => 'e205221dd32dc53ebfc9fb48cbdecd9e').enabled?.should eq(false)
|
31
|
+
|
32
|
+
# The blast button should still be disabled
|
33
|
+
b.button(:id => 'method').text.should eq('BLAST')
|
34
|
+
b.button(:id => 'method').enabled?.should eq(false)
|
35
|
+
|
36
|
+
# Give a sequence we know should hit
|
37
|
+
b.textarea(:name => 'sequence').set 'YTLPPPPTKLYSAPISCRKNKTGHWMDDILSIKTGESCPVNNYLHSGFLA'
|
38
|
+
|
39
|
+
#blast butn now active
|
40
|
+
b.button(:id => 'method').text.should eq('BLASTP')
|
41
|
+
b.button(:id => 'method').enabled?.should eq(true)
|
42
|
+
|
43
|
+
# Run the blast
|
44
|
+
b.button(:id => 'method').click
|
45
|
+
|
46
|
+
while b.div(:id => 'result').text.include?('Waiting for BLAST to be run')
|
47
|
+
end
|
48
|
+
|
49
|
+
# blast should have worked
|
50
|
+
b.div(:id => 'result').text.include?('Sequences producing significant alignments: ').should eq(true)
|
51
|
+
end
|
52
|
+
end
|
53
|
+
|
54
|
+
#####################################################################################
|
55
|
+
#+++++++++++ Below is admin code, hopefully not necessary to mess around with to test new UI specs
|
56
|
+
|
57
|
+
# NOT thread-safe, at least because of the interaction with headless
|
58
|
+
class BrowserAdmin
|
59
|
+
def self.setup_browser(type)
|
60
|
+
case type
|
61
|
+
when :firefox then
|
62
|
+
Watir::Browser.new :firefox
|
63
|
+
when :chrome then
|
64
|
+
Watir::Browser.new :chrome
|
65
|
+
when :headless_firefox then
|
66
|
+
@headless = Headless.new
|
67
|
+
@headless.start
|
68
|
+
Watir::Browser.new :firefox
|
69
|
+
when :headless_chrome then
|
70
|
+
@headless = Headless.new
|
71
|
+
@headless.start
|
72
|
+
Watir::Browser.new :chrome
|
73
|
+
else
|
74
|
+
raise "Unknown browser type asked for: #{type.inspect}"
|
75
|
+
end
|
76
|
+
end
|
77
|
+
|
78
|
+
def self.teardown_browser(browser)
|
79
|
+
browser.close
|
80
|
+
|
81
|
+
# Re-head again, but maybe this makes no difference
|
82
|
+
@headless.destroy unless @headless.nil?
|
83
|
+
@headless = nil
|
84
|
+
end
|
85
|
+
end
|
86
|
+
|
87
|
+
|
88
|
+
describe 'ui' do
|
89
|
+
[:firefox, :chrome, :headless_firefox, :headless_chrome].each do |bro|
|
90
|
+
context bro.to_s do
|
91
|
+
it_behaves_like 'a browser' do
|
92
|
+
browser = nil
|
93
|
+
before do
|
94
|
+
browser = BrowserAdmin.setup_browser bro
|
95
|
+
end
|
96
|
+
after do
|
97
|
+
BrowserAdmin.teardown_browser browser
|
98
|
+
end
|
99
|
+
let(:b){browser}
|
100
|
+
end
|
101
|
+
end
|
102
|
+
end
|
103
|
+
end
|
104
|
+
|
data/tests/ui.specs.todo
ADDED
@@ -0,0 +1,10 @@
|
|
1
|
+
it "should automatically focus sequence input box" do
|
2
|
+
# when the page loads, check that sequence input box is focussed
|
3
|
+
#
|
4
|
+
# NOTE: unless #75 is resolved, make sure to test this functionality only if
|
5
|
+
# HTML5 autofocus attribute is supported
|
6
|
+
end
|
7
|
+
|
8
|
+
it "should ensure spell checking is disabled for sequence input box" do
|
9
|
+
# NOTE: only if the browser supports it
|
10
|
+
end
|
data/views/500.erb
ADDED
@@ -0,0 +1,22 @@
|
|
1
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
2
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
3
|
+
<html xml:lang="en" lang="en" xmlns="http://www.w3.org/1999/xhtml">
|
4
|
+
<head>
|
5
|
+
<title>SequenceServer</title>
|
6
|
+
<meta name="author" content="Anurag Priyam" />
|
7
|
+
<meta name="author" content="Yannick Wurm" />
|
8
|
+
<meta name="author" content="Cedric Wurm" />
|
9
|
+
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type"/>
|
10
|
+
|
11
|
+
<%# without a space after erb's closing tag, a / gets appended to css' path %>
|
12
|
+
<link rel="stylesheet" media="screen" type="text/css" href=<%= uri('/css/beige.css') %> />
|
13
|
+
</head>
|
14
|
+
|
15
|
+
<body>
|
16
|
+
<div class="container">
|
17
|
+
<h1>Oops! Something went wonky!</h1>
|
18
|
+
<p>Apologies, there was an error with your request:
|
19
|
+
<strong><%=request.env['sinatra.error'].message %> </strong></p>
|
20
|
+
<p>If the error persists please contact the administrator</p>
|
21
|
+
</div>
|
22
|
+
</body>
|
data/views/_options.erb
ADDED
@@ -0,0 +1,144 @@
|
|
1
|
+
<%#
|
2
|
+
|
3
|
+
NOTE: The markup below is displayed in a modal window. Use less than 70
|
4
|
+
characters per line to preserve formatting.
|
5
|
+
%>
|
6
|
+
|
7
|
+
<h6>General Search Options</h6>
|
8
|
+
|
9
|
+
<br/>
|
10
|
+
|
11
|
+
<ul class="unstyled">
|
12
|
+
<li>
|
13
|
+
<pre><%= ERB::Util.h %q|-evalue <Real>
|
14
|
+
Expectation value (E) threshold for saving hits
|
15
|
+
Default = '10'| %></pre>
|
16
|
+
</li>
|
17
|
+
<li>
|
18
|
+
<pre><%= ERB::Util.h %q|-word_size <Integer, >=2>
|
19
|
+
Word size for wordfinder algorithm| %></pre>
|
20
|
+
</li>
|
21
|
+
<li>
|
22
|
+
<pre><%= ERB::Util.h %q|-gapopen <Integer>
|
23
|
+
Cost to open a gap| %></pre>
|
24
|
+
</li>
|
25
|
+
<li>
|
26
|
+
<pre><%= ERB::Util.h %q|-gapextend <Integer>
|
27
|
+
Cost to extend a gap| %></pre>
|
28
|
+
</li>
|
29
|
+
<li>
|
30
|
+
<pre><%= ERB::Util.h %q|-matrix <String>
|
31
|
+
Scoring matrix name (normally BLOSUM62)| %></pre>
|
32
|
+
</li>
|
33
|
+
<li>
|
34
|
+
<pre><%= ERB::Util.h %q|-threshold <Real, >=0>
|
35
|
+
Minimum word score such that the word is added to the BLAST lookup
|
36
|
+
table| %></pre>
|
37
|
+
</li>
|
38
|
+
<li>
|
39
|
+
<pre><%= ERB::Util.h %q|-comp_based_stats <String>
|
40
|
+
Use composition-based statistics for blastp / tblastn:
|
41
|
+
D or d: default (equivalent to 2)
|
42
|
+
0 or F or f: no composition-based statistics
|
43
|
+
1: Composition-based statistics as in NAR 29:2994-3005, 2001
|
44
|
+
2 or T or t : Composition-based score adjustment as in
|
45
|
+
Bioinformatics 21:902-911, 2005, conditioned on sequence
|
46
|
+
properties
|
47
|
+
3: Composition-based score adjustment as in Bioinformatics
|
48
|
+
21:902-911, 2005, unconditionally
|
49
|
+
For programs other than tblastn, must either be absent or be D, F
|
50
|
+
or 0
|
51
|
+
Default = `2'| %></pre>
|
52
|
+
</li>
|
53
|
+
<li>
|
54
|
+
<pre><%= ERB::Util.h %q|-num_descriptions <Integer, >=0>
|
55
|
+
Number of database sequences to show one-line descriptions for
|
56
|
+
Default = `500'| %></pre>
|
57
|
+
</li>
|
58
|
+
<li>
|
59
|
+
<pre><%= ERB::Util.h %q| -num_alignments <Integer, >=0>
|
60
|
+
Number of database sequences to show alignments for
|
61
|
+
Default = `250'| %></pre>
|
62
|
+
</li>
|
63
|
+
</ul>
|
64
|
+
|
65
|
+
<br/>
|
66
|
+
|
67
|
+
<h6>Query filtering options</h6>
|
68
|
+
|
69
|
+
<br/>
|
70
|
+
|
71
|
+
<ul class="unstyled">
|
72
|
+
<li>
|
73
|
+
<pre><%= ERB::Util.h %q|-seg <String>
|
74
|
+
Filter query sequence with SEG (Format: 'yes', 'window locut hicut',
|
75
|
+
or 'no' to disable)
|
76
|
+
Default = `no'| %></pre>
|
77
|
+
</li>
|
78
|
+
<li>
|
79
|
+
<pre><%= ERB::Util.h %q|-soft_masking <Boolean>
|
80
|
+
Apply filtering locations as soft masks
|
81
|
+
Default = `false'| %></pre>
|
82
|
+
</li>
|
83
|
+
<li>
|
84
|
+
<pre><%= ERB::Util.h %q|-lcase_masking
|
85
|
+
Use lower case filtering in query and subject sequence(s)?| %></pre>
|
86
|
+
</li>
|
87
|
+
</ul>
|
88
|
+
|
89
|
+
<br/>
|
90
|
+
|
91
|
+
<h6>Restrict search or results</h6>
|
92
|
+
|
93
|
+
<br/>
|
94
|
+
|
95
|
+
<ul class="unstyled">
|
96
|
+
<li>
|
97
|
+
<pre><%= ERB::Util.h %q|-gilist <String>
|
98
|
+
Restrict search of database to list of GI's
|
99
|
+
* Incompatible with: negative_gilist, seqidlist, remote, subject,
|
100
|
+
subject_loc| %></pre>
|
101
|
+
</li>
|
102
|
+
<li>
|
103
|
+
<pre><%= ERB::Util.h %q|-seqidlist <String>
|
104
|
+
Restrict search of database to list of SeqId's
|
105
|
+
* Incompatible with: gilist, negative_gilist, remote, subject,
|
106
|
+
subject_loc| %></pre>
|
107
|
+
</li>
|
108
|
+
<li>
|
109
|
+
<pre><%= ERB::Util.h %q|-negative_gilist <String>
|
110
|
+
Restrict search of database to everything except the listed GIs
|
111
|
+
* Incompatible with: gilist, seqidlist, remote, subject,
|
112
|
+
subject_loc| %></pre>
|
113
|
+
</li>
|
114
|
+
<li>
|
115
|
+
<pre><%= ERB::Util.h %q|-entrez_query <String>
|
116
|
+
Restrict search with the given Entrez query
|
117
|
+
* Requires: remote| %></pre>
|
118
|
+
</li>
|
119
|
+
<li>
|
120
|
+
<pre><%= ERB::Util.h %q|-db_soft_mask <String>
|
121
|
+
Filtering algorithm ID to apply to the BLAST database as soft masking
|
122
|
+
* Incompatible with: subject, subject_loc| %></pre>
|
123
|
+
</li>
|
124
|
+
<li>
|
125
|
+
<pre><%= ERB::Util.h %q|-culling_limit <Integer, >=0>
|
126
|
+
If the query range of a hit is enveloped by that of at least this
|
127
|
+
many higher-scoring hits, delete the hit
|
128
|
+
* Incompatible with: best_hit_overhang, best_hit_score_edge| %></pre>
|
129
|
+
</li>
|
130
|
+
<li>
|
131
|
+
<pre><%= ERB::Util.h %q|-best_hit_overhang <Real, (>0 and <0.5)>
|
132
|
+
Best Hit algorithm overhang value (recommended value: 0.1)
|
133
|
+
* Incompatible with: culling_limit| %></pre>
|
134
|
+
</li>
|
135
|
+
<li>
|
136
|
+
<pre><%= ERB::Util.h %q|-best_hit_score_edge <Real, (>0 and <0.5)>
|
137
|
+
Best Hit algorithm score edge value (recommended value: 0.1)
|
138
|
+
* Incompatible with: culling_limit| %></pre>
|
139
|
+
</li>
|
140
|
+
<li>
|
141
|
+
<pre><%= ERB::Util.h %q|-max_target_seqs <Integer, >=1>
|
142
|
+
Maximum number of aligned sequences to keep| %></pre>
|
143
|
+
</li>
|
144
|
+
</ul>
|