bio-table 0.8.0 → 0.9.0
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/.travis.yml +3 -7
- data/Gemfile +5 -6
- data/README.md +44 -5
- data/VERSION +1 -1
- data/bin/bio-table +20 -4
- data/lib/bio-table.rb +1 -0
- data/lib/bio-table/filter.rb +16 -4
- data/lib/bio-table/parsers/fastareader.rb +141 -0
- data/lib/bio-table/rewrite.rb +5 -0
- data/lib/bio-table/statistics.rb +6 -1
- data/lib/bio-table/table_apply.rb +2 -1
- data/test/data/input/aa.fa +7 -0
- metadata +70 -60
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 208de532730ef88e9a1ecc2961f08ceaa464d846
|
4
|
+
data.tar.gz: 4b88172ae40141a1db2dcb5c3a7b55daeea1beed
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 5d0a5f044e44a89fd047db4443fca2d8729af55f0cc7106ab45e939e3e92c7356dffd7f9308a63cb4a0ff39b313c9321edf3cb637af587f8b7ff8796c1083415
|
7
|
+
data.tar.gz: cb9abfe846b2c1949d027e38415e486719cf59db5fb99d38ec495b1b828d8a838dca19ee63c302844f82fb23dc4ec2a61c1749cbfb286f77ac0eecffa14e470e
|
data/.travis.yml
CHANGED
@@ -1,12 +1,8 @@
|
|
1
1
|
language: ruby
|
2
2
|
rvm:
|
3
|
-
- 1.9.2
|
4
3
|
- 1.9.3
|
5
|
-
-
|
6
|
-
|
7
|
-
# -
|
8
|
-
# - jruby-18mode # JRuby in 1.8 mode
|
9
|
-
# - rbx-18mode
|
10
|
-
|
4
|
+
- 2.1.0
|
5
|
+
- ruby-head
|
6
|
+
# - jruby-head
|
11
7
|
# uncomment this line if your project needs to run something other than `rake`:
|
12
8
|
# script: bundle exec rspec spec
|
data/Gemfile
CHANGED
@@ -8,12 +8,11 @@ gem "bio-logger"
|
|
8
8
|
# Add dependencies to develop your gem here.
|
9
9
|
# Include everything needed to run rake, tests, features, etc.
|
10
10
|
group :development do
|
11
|
-
gem "rspec"
|
12
|
-
gem "
|
13
|
-
gem "
|
14
|
-
gem "
|
15
|
-
gem "jeweler", "~> 1.8.3"
|
11
|
+
gem "rspec"
|
12
|
+
gem "cucumber"
|
13
|
+
gem "bundler"
|
14
|
+
gem "jeweler", "~> 2.0.0"
|
16
15
|
gem "bio", ">= 1.4.2"
|
17
|
-
gem "rdoc"
|
16
|
+
gem "rdoc"
|
18
17
|
gem "regressiontest", ">= 0.0.2"
|
19
18
|
end
|
data/README.md
CHANGED
@@ -46,6 +46,7 @@ Features:
|
|
46
46
|
* Convert key-value (attributes) to RDF (nyi)
|
47
47
|
* Convert table to JSON/YAML/XML (nyi)
|
48
48
|
* Transpose matrix (nyi)
|
49
|
+
* Convert a FASTA file to a table
|
49
50
|
* etc. etc.
|
50
51
|
|
51
52
|
and bio-table is pretty fast. To convert a 3Mb file of 18670 rows
|
@@ -86,7 +87,10 @@ When you have a special file format, it is also possible to use a string or rege
|
|
86
87
|
bio-table --in-format regex --split-on '\s*,\s*' file
|
87
88
|
```
|
88
89
|
|
89
|
-
To filter out rows that contain certain values
|
90
|
+
To filter out rows that contain certain values, i.e., filter on the
|
91
|
+
third column that have values less than 0.05 (this is actually the 5th
|
92
|
+
column in a tabular file, where the fist column is the row name and
|
93
|
+
the others count from zero).
|
90
94
|
|
91
95
|
```sh
|
92
96
|
bio-table table1.csv --num-filter "values[3] <= 0.05"
|
@@ -135,7 +139,7 @@ which takes the first 13 fields and compact removes the nil values.
|
|
135
139
|
To filter out all rows with more than 3 NA values:
|
136
140
|
|
137
141
|
```sh
|
138
|
-
bio-table table.csv --num-filter 'values.
|
142
|
+
bio-table table.csv --num-filter 'values.size - values.compact.size > 3'
|
139
143
|
```
|
140
144
|
|
141
145
|
Also string comparisons and regular expressions can be used. E.g.
|
@@ -201,6 +205,21 @@ again
|
|
201
205
|
where we rewrite the rowname in capitals, and set the second field to
|
202
206
|
empty if the third field is below 0.25.
|
203
207
|
|
208
|
+
Say we need a log transform, we can also transform and rewrite a full matrix with:
|
209
|
+
|
210
|
+
```sh
|
211
|
+
bio-table table1.csv --rewrite 'fields = fields.map { |f| Math::log(f.to_f) }'
|
212
|
+
```
|
213
|
+
|
214
|
+
Note that 'fields' is an alias for 'field', but do not use them in the same expression.
|
215
|
+
Another option is to use (lazy) values:
|
216
|
+
|
217
|
+
```sh
|
218
|
+
bio-table table1.csv --rewrite 'fields = values.map { |v| Math::log(v) }'
|
219
|
+
```
|
220
|
+
|
221
|
+
which saves the typing to to_f.
|
222
|
+
|
204
223
|
### Statistics
|
205
224
|
|
206
225
|
bio-table can handle some column statistics using the Ruby statsample
|
@@ -210,7 +229,7 @@ gem
|
|
210
229
|
gem install statsample
|
211
230
|
```
|
212
231
|
|
213
|
-
(statsample is not loaded by default
|
232
|
+
(statsample is not loaded by default because it has a host of
|
214
233
|
dependencies)
|
215
234
|
|
216
235
|
Thereafter, to calculate the stats for columns 1 and 2 (rowname is column 0)
|
@@ -247,7 +266,14 @@ You can combine/concat two or more tables by passing in multiple file names
|
|
247
266
|
```
|
248
267
|
|
249
268
|
this will append table2 to table1, assuming they have the same headers
|
250
|
-
(you can use the --columns switch!)
|
269
|
+
(you can use the --columns switch at the same time!). With --skip
|
270
|
+
the header lines are skipped in every file. This can be a real asset
|
271
|
+
when using the Unix split command on input files and combining output
|
272
|
+
files again. Something this might work:
|
273
|
+
|
274
|
+
```sh
|
275
|
+
ls run/*.out -1|sort|xargs bio-table --skip 3
|
276
|
+
```
|
251
277
|
|
252
278
|
To combine tables side by side use the --merge switch:
|
253
279
|
|
@@ -261,6 +287,7 @@ with NA's, unless you add a filter, e.g.
|
|
261
287
|
|
262
288
|
```sh
|
263
289
|
bio-table --merge table1.csv table2.csv --num-filter "values.compact.size == values.size"
|
290
|
+
|
264
291
|
```
|
265
292
|
|
266
293
|
### Splitting a table
|
@@ -310,7 +337,19 @@ finds the overlapping rows, based on the content of column 2.
|
|
310
337
|
bio-table currently reads comma separated files and tab delimited
|
311
338
|
files.
|
312
339
|
|
313
|
-
|
340
|
+
bio-table can also parse a FASTA file and turn it into a table using
|
341
|
+
a flexible regular expression to fetch the IDs
|
342
|
+
|
343
|
+
```sh
|
344
|
+
bio-table --fasta '^(\S+)' test/data/input/aa.fa
|
345
|
+
```
|
346
|
+
|
347
|
+
notice the parentheses - these capture the ID and create the first
|
348
|
+
column. If two captures are defined another column gets added. Try
|
349
|
+
|
350
|
+
```sh
|
351
|
+
bio-table --fasta '^(\S+).*?(\d+) aa' test/data/input/aa.fa
|
352
|
+
```
|
314
353
|
|
315
354
|
### Using STDIN
|
316
355
|
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.
|
1
|
+
0.9.0
|
data/bin/bio-table
CHANGED
@@ -38,7 +38,6 @@ options[:show_help] = true if ARGV.size == 0 and not INPUT_ON_STDIN
|
|
38
38
|
opts = OptionParser.new do |o|
|
39
39
|
o.banner = "Usage: #{File.basename($0)} [options] filename\n\n"
|
40
40
|
|
41
|
-
|
42
41
|
o.on('--num-filter expression', 'Numeric filtering function') do |par|
|
43
42
|
options[:num_filter] = par
|
44
43
|
end
|
@@ -130,6 +129,10 @@ opts = OptionParser.new do |o|
|
|
130
129
|
options[:evaluate] = s
|
131
130
|
end
|
132
131
|
|
132
|
+
o.on("--fasta regex",String,"Read FASTA format creating ID with regex") do | regex |
|
133
|
+
options[:fasta] = regex
|
134
|
+
end
|
135
|
+
|
133
136
|
o.on('--blank-nodes','Output (RDF) blank nodes - allowing for duplicate row names') do
|
134
137
|
options[:blank_nodes] = true
|
135
138
|
end
|
@@ -137,7 +140,7 @@ opts = OptionParser.new do |o|
|
|
137
140
|
o.on('--statistics','Output column statistics') do
|
138
141
|
options[:statistics] = true
|
139
142
|
end
|
140
|
-
|
143
|
+
|
141
144
|
o.separator "\n\tVerbosity:\n\n"
|
142
145
|
|
143
146
|
o.on("--logger filename",String,"Log to file (default stderr)") do | name |
|
@@ -183,7 +186,7 @@ end
|
|
183
186
|
|
184
187
|
Bio::Log::CLI.configure('bio-table')
|
185
188
|
logger = Bio::Log::LoggerPlus['bio-table']
|
186
|
-
logger.info [options
|
189
|
+
logger.info [options]
|
187
190
|
|
188
191
|
include BioTable
|
189
192
|
|
@@ -207,6 +210,17 @@ if options[:overlap]
|
|
207
210
|
exit
|
208
211
|
end
|
209
212
|
|
213
|
+
if options[:fasta]
|
214
|
+
logger.warn "Column settings are ignored for --fasta" if options[:columns]
|
215
|
+
ARGV.each do | fn |
|
216
|
+
print "id\tseq\n"
|
217
|
+
FastaReader.new(fn,options[:fasta]).each do | rec |
|
218
|
+
print rec.id,"\t",rec.seq,"\n"
|
219
|
+
end
|
220
|
+
end
|
221
|
+
exit
|
222
|
+
end
|
223
|
+
|
210
224
|
if options[:merge]
|
211
225
|
ts = []
|
212
226
|
ARGV.each do | fn |
|
@@ -233,10 +247,12 @@ writer =
|
|
233
247
|
|
234
248
|
if INPUT_ON_STDIN
|
235
249
|
opts = options.dup # so we can 'safely' modify options
|
250
|
+
has_input = false
|
236
251
|
BioTable::TableLoader.emit(STDIN, opts).each do |row, type|
|
237
252
|
writer.write(TableRow.new(row[0],row[1..-1]),type)
|
253
|
+
has_input = true
|
238
254
|
end
|
239
|
-
options[:write_header] = false # don't write the header for chained files
|
255
|
+
options[:write_header] = false if has_input # don't write the header for chained files
|
240
256
|
end
|
241
257
|
|
242
258
|
statistics = if options[:statistics]
|
data/lib/bio-table.rb
CHANGED
data/lib/bio-table/filter.rb
CHANGED
@@ -1,6 +1,10 @@
|
|
1
1
|
module BioTable
|
2
2
|
|
3
|
+
# LazyValues fetches values on demand from the @fields array. In the [] method
|
4
|
+
# a field is transformed into a float when it is called.
|
5
|
+
|
3
6
|
class LazyValues
|
7
|
+
|
4
8
|
include Enumerable
|
5
9
|
|
6
10
|
def initialize fields
|
@@ -16,12 +20,16 @@ module BioTable
|
|
16
20
|
@values[index]
|
17
21
|
end
|
18
22
|
|
19
|
-
def each
|
20
|
-
@fields.each_with_index do |
|
21
|
-
|
23
|
+
def each &block
|
24
|
+
@fields.each_with_index do |field,i|
|
25
|
+
if block_given?
|
26
|
+
block.call self[i]
|
27
|
+
else
|
28
|
+
yield self[i]
|
29
|
+
end
|
22
30
|
end
|
23
31
|
end
|
24
|
-
|
32
|
+
|
25
33
|
def compact
|
26
34
|
a = []
|
27
35
|
each do | e |
|
@@ -29,6 +37,10 @@ module BioTable
|
|
29
37
|
end
|
30
38
|
a
|
31
39
|
end
|
40
|
+
|
41
|
+
def size
|
42
|
+
@fields.size
|
43
|
+
end
|
32
44
|
end
|
33
45
|
|
34
46
|
module Filter
|
@@ -0,0 +1,141 @@
|
|
1
|
+
# FastaReader (originally from BigBio)
|
2
|
+
#
|
3
|
+
|
4
|
+
|
5
|
+
class FastaRecord
|
6
|
+
attr_accessor :id, :descr, :seq
|
7
|
+
|
8
|
+
def initialize id, descr, seq
|
9
|
+
@id = id
|
10
|
+
@descr = descr
|
11
|
+
@seq = seq
|
12
|
+
end
|
13
|
+
end
|
14
|
+
|
15
|
+
class FastaReader
|
16
|
+
|
17
|
+
# Initalize the reader of FASTA file _fn_. Options can be :regex and
|
18
|
+
# :index (true/false)
|
19
|
+
def initialize fn, regex = nil
|
20
|
+
@logger = Bio::Log::LoggerPlus['bio-table']
|
21
|
+
@f = File.open(fn)
|
22
|
+
@fread_once = false
|
23
|
+
@regex = regex
|
24
|
+
@regex = '^(\S+)' if @regex == nil
|
25
|
+
@regex = '('+regex+')' if regex !~ /\(/
|
26
|
+
@logger.info "Parsing FASTA with ID regex '"+@regex+"'"
|
27
|
+
end
|
28
|
+
|
29
|
+
# Parse the FASTA file and yield id, descr, sequence. When the indexer is on
|
30
|
+
# it will index the records the first time. Note that, with indexing, when
|
31
|
+
# you don't complete parsing there will be an error the second time. This is
|
32
|
+
# a # trade-off, otherwise one would always have to index the file and read
|
33
|
+
# it twice.
|
34
|
+
def parse_each
|
35
|
+
@f.seek 0 # force file rewind
|
36
|
+
@rec_fpos = 0
|
37
|
+
@rec_line = @f.gets
|
38
|
+
fpos = 0
|
39
|
+
@count = 0
|
40
|
+
begin
|
41
|
+
# digest id from record description
|
42
|
+
id, descr = digest_tag(@rec_line)
|
43
|
+
id_fpos = @rec_fpos
|
44
|
+
# parse the sequence
|
45
|
+
seq = ""
|
46
|
+
begin
|
47
|
+
fpos = @f.tell
|
48
|
+
line = @f.gets
|
49
|
+
break if line =~ /^>/
|
50
|
+
seq += line.strip
|
51
|
+
end while !@f.eof
|
52
|
+
# new record
|
53
|
+
@count += 1
|
54
|
+
@rec_fpos = fpos
|
55
|
+
@rec_line = line
|
56
|
+
# p [@rec_line, id, id_fpos]
|
57
|
+
# indexer_set(id, id_fpos) if @indexer and not @fread_once
|
58
|
+
yield id, descr, seq
|
59
|
+
end while !@f.eof
|
60
|
+
@fread_once = true
|
61
|
+
end
|
62
|
+
|
63
|
+
# returns a FastaRecord for every item (invokes parse_each)
|
64
|
+
def each
|
65
|
+
parse_each { | id, descr, seq | yield FastaRecord.new(id, descr, seq) }
|
66
|
+
end
|
67
|
+
|
68
|
+
def first
|
69
|
+
parse_each { | id, descr, seq |
|
70
|
+
return FastaRecord.new(id, descr, seq)
|
71
|
+
}
|
72
|
+
end
|
73
|
+
|
74
|
+
# Return a record by its +id+, nil when not found
|
75
|
+
def get id
|
76
|
+
indexed?
|
77
|
+
if fpos = indexer_get(id)
|
78
|
+
get_rec(fpos)
|
79
|
+
else
|
80
|
+
nil
|
81
|
+
end
|
82
|
+
end
|
83
|
+
|
84
|
+
def get_rec fpos
|
85
|
+
@f.seek fpos
|
86
|
+
tag = @f.gets
|
87
|
+
seq = ""
|
88
|
+
begin
|
89
|
+
line = @f.gets
|
90
|
+
break if line =~ /^>/
|
91
|
+
seq += line.strip
|
92
|
+
end while !@f.eof
|
93
|
+
id, descr = digest_tag(tag)
|
94
|
+
FastaRecord.new(id,descr,seq)
|
95
|
+
end
|
96
|
+
|
97
|
+
def get_by_index idx
|
98
|
+
indexed?
|
99
|
+
if fpos = indexer_get_by_index(idx)[1]
|
100
|
+
ret = get_rec(fpos)
|
101
|
+
return ret
|
102
|
+
end
|
103
|
+
nil
|
104
|
+
end
|
105
|
+
|
106
|
+
def digest_tag tag
|
107
|
+
if tag =~ /^>/
|
108
|
+
descr = $'.strip
|
109
|
+
matches = /#{@regex}/.match(descr).captures
|
110
|
+
if matches.size > 0
|
111
|
+
# p matches
|
112
|
+
return matches.join("\t"), descr
|
113
|
+
end
|
114
|
+
p descr # do not remove these
|
115
|
+
p @regex
|
116
|
+
end
|
117
|
+
raise "Can not digest '#{tag}' using '"+@regex+"'"
|
118
|
+
end
|
119
|
+
|
120
|
+
# Returns the size of the dataset - as read. After the final
|
121
|
+
# record the size represents the number of items in the FASTA file
|
122
|
+
def size
|
123
|
+
@count
|
124
|
+
end
|
125
|
+
|
126
|
+
def close
|
127
|
+
@f.close
|
128
|
+
end
|
129
|
+
|
130
|
+
private
|
131
|
+
|
132
|
+
def indexed?
|
133
|
+
if @indexer and not @fread_once
|
134
|
+
# force indexer
|
135
|
+
# $stderr.print "Force indexer"
|
136
|
+
parse_each { | x, y, z | nil }
|
137
|
+
end
|
138
|
+
true
|
139
|
+
end
|
140
|
+
|
141
|
+
end
|
data/lib/bio-table/rewrite.rb
CHANGED
@@ -2,7 +2,11 @@ module BioTable
|
|
2
2
|
|
3
3
|
module Rewrite
|
4
4
|
|
5
|
+
# Rewrite fields. Both field and fields can be used, but not at the same time.
|
5
6
|
def Rewrite::rewrite code, rowname, field
|
7
|
+
fields = field
|
8
|
+
original = field
|
9
|
+
values = LazyValues.new(field)
|
6
10
|
return rowname,field if not code or code==""
|
7
11
|
begin
|
8
12
|
eval(code)
|
@@ -10,6 +14,7 @@ module BioTable
|
|
10
14
|
$stderr.print "Failed to evaluate ",rowname," ",field," with ",code,"\n"
|
11
15
|
raise
|
12
16
|
end
|
17
|
+
field = fields if fields != original
|
13
18
|
return rowname,field
|
14
19
|
end
|
15
20
|
end
|
data/lib/bio-table/statistics.rb
CHANGED
@@ -29,6 +29,7 @@ module BioTable
|
|
29
29
|
@include_rownames = options[:with_rownames]
|
30
30
|
@logger.debug "Include row names" if @include_rownames
|
31
31
|
@first_column = (@include_rownames ? 0 : 1)
|
32
|
+
@write_header = options[:write_header]
|
32
33
|
end
|
33
34
|
|
34
35
|
def parse_header(line, options)
|
@@ -39,7 +40,7 @@ module BioTable
|
|
39
40
|
if options[:unshift_headers]
|
40
41
|
header.unshift("ID")
|
41
42
|
end
|
42
|
-
@logger.info(header) if @logger
|
43
|
+
@logger.info(header) if @logger and @write_header
|
43
44
|
header
|
44
45
|
end
|
45
46
|
|
@@ -0,0 +1,7 @@
|
|
1
|
+
>PITG_20587T0 | PITG_20587 | Phytophthora infestans cysteine protease family C48, putative (translation) (349 aa) | paired
|
2
|
+
MQLRALLRDNDVCDVVSTLWMIMPGVREVWSFLTTFPVNKNGEGRSIQWRVDGDYVPDRVRFRLVESLVDDASDKLRGGLALDEEIELDSDGERMSSIESYVVSIEKVGQFTREQLEAMKSLWGLQDTCRNAVLCCTWLNSTVKPAVSDPASAGIIMGKILECWPYTSLVGFGFDLTYNNLFCFRDSAWLNDNAMRAFAVSKDAKNGTQPKATKSRISTSTLDKVGESVASHQFVLLPINFGGTHWGCLVVDRDTKVIKMYDSMGGKRNKKRLQKMAEEIRTGPLRDDSYEALEVTEPVQTNSDSCGVFVCRFFWTCVSSESPSDVSPAGITKLRWEMLHAVTKLRPR*
|
3
|
+
>PITG_04498T0 | PITG_04498 | Phytophthora infestans cysteine protease family C48, putative (translation) (337 aa) | paired
|
4
|
+
MKLRALLRDNDVCDVVSTLWMIMPGVREVGSFLTTFPLNKNGEGRSIQWRVDGDYVPDRVRFRLVESLVDDALDKLRGGLALDEEIELDRDGERMGSIESYVVSIEKVGQFTREQLEAMKSLWGLQDTCRNAVLCCTWLNSTVKPACWPYTPLVGFGFDLTYNNLFCFRDSAWLNDNAMRAFAVCLARYKNNCTVVIPPPKKAKDAKNGTQPKATKSRISTSTLDKVGESVASHQFVLLPINFGGTHWGCLVVKRDTKVIKMYDSMGGKRNKKRLQKMAEEIRTGPLRDDSYEALEVTEPVQTDSDSCGVFVDVSPAGITKLRWEMLHAVMKLRPR*
|
5
|
+
>PITG_10111T0 | PITG_10111 | Phytophthora infestans cysteine protease family C48, putative (translation) (332 aa) | paired
|
6
|
+
MKLRALLRDNDVCDVVSTLWMIMPGVREVGSFLTTFPVNKNGEGRSIQWRVDGDYVPDRVRFRLVESLVDDASDKLRGGLALDEEIELDTGQLTREQLEAMKSLWGLQDTCRNAVLCCTWLNSTILECWPYTPLVGFGFDLTYTNLFCFRDSAWLNDNAMRAFAVCLARYKNNCTVVIPPPQKAKDAKNGTQPKATKSRISTSTLDKVGESVASHQFVLLPINFGGTHWGCLVVDRDTKVVKMYDSMGGKRNKKRLEKMAEEIRTGPLRDDSYKALEVTEPVQTDSDSCGVFVCRFFWTCVSSESPSDVSPAGITKLRWEMLHAVMKLRPR*
|
7
|
+
|
metadata
CHANGED
@@ -1,115 +1,127 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bio-table
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
5
|
-
prerelease:
|
4
|
+
version: 0.9.0
|
6
5
|
platform: ruby
|
7
6
|
authors:
|
8
7
|
- Pjotr Prins
|
9
8
|
autorequire:
|
10
9
|
bindir: bin
|
11
10
|
cert_chain: []
|
12
|
-
date:
|
11
|
+
date: 2014-02-27 00:00:00.000000000 Z
|
13
12
|
dependencies:
|
14
13
|
- !ruby/object:Gem::Dependency
|
15
14
|
name: bio-logger
|
16
|
-
requirement:
|
17
|
-
none: false
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
18
16
|
requirements:
|
19
|
-
- -
|
17
|
+
- - ">="
|
20
18
|
- !ruby/object:Gem::Version
|
21
19
|
version: '0'
|
22
20
|
type: :runtime
|
23
21
|
prerelease: false
|
24
|
-
version_requirements:
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ">="
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0'
|
25
27
|
- !ruby/object:Gem::Dependency
|
26
28
|
name: rspec
|
27
|
-
requirement:
|
28
|
-
none: false
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
29
30
|
requirements:
|
30
|
-
- -
|
31
|
+
- - ">="
|
31
32
|
- !ruby/object:Gem::Version
|
32
|
-
version:
|
33
|
+
version: '0'
|
33
34
|
type: :development
|
34
35
|
prerelease: false
|
35
|
-
version_requirements:
|
36
|
-
- !ruby/object:Gem::Dependency
|
37
|
-
name: rdoc
|
38
|
-
requirement: &23239900 !ruby/object:Gem::Requirement
|
39
|
-
none: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
40
37
|
requirements:
|
41
|
-
- -
|
38
|
+
- - ">="
|
42
39
|
- !ruby/object:Gem::Version
|
43
|
-
version: '
|
44
|
-
type: :development
|
45
|
-
prerelease: false
|
46
|
-
version_requirements: *23239900
|
40
|
+
version: '0'
|
47
41
|
- !ruby/object:Gem::Dependency
|
48
42
|
name: cucumber
|
49
|
-
requirement:
|
50
|
-
none: false
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
51
44
|
requirements:
|
52
|
-
- -
|
45
|
+
- - ">="
|
53
46
|
- !ruby/object:Gem::Version
|
54
47
|
version: '0'
|
55
48
|
type: :development
|
56
49
|
prerelease: false
|
57
|
-
version_requirements:
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
58
55
|
- !ruby/object:Gem::Dependency
|
59
56
|
name: bundler
|
60
|
-
requirement:
|
61
|
-
none: false
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
62
58
|
requirements:
|
63
|
-
- -
|
59
|
+
- - ">="
|
64
60
|
- !ruby/object:Gem::Version
|
65
|
-
version:
|
61
|
+
version: '0'
|
66
62
|
type: :development
|
67
63
|
prerelease: false
|
68
|
-
version_requirements:
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: jeweler
|
71
|
-
requirement:
|
72
|
-
none: false
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
73
72
|
requirements:
|
74
|
-
- - ~>
|
73
|
+
- - "~>"
|
75
74
|
- !ruby/object:Gem::Version
|
76
|
-
version:
|
75
|
+
version: 2.0.0
|
77
76
|
type: :development
|
78
77
|
prerelease: false
|
79
|
-
version_requirements:
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: 2.0.0
|
80
83
|
- !ruby/object:Gem::Dependency
|
81
84
|
name: bio
|
82
|
-
requirement:
|
83
|
-
none: false
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
84
86
|
requirements:
|
85
|
-
- -
|
87
|
+
- - ">="
|
86
88
|
- !ruby/object:Gem::Version
|
87
89
|
version: 1.4.2
|
88
90
|
type: :development
|
89
91
|
prerelease: false
|
90
|
-
version_requirements:
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: 1.4.2
|
91
97
|
- !ruby/object:Gem::Dependency
|
92
98
|
name: rdoc
|
93
|
-
requirement:
|
94
|
-
none: false
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
95
100
|
requirements:
|
96
|
-
- -
|
101
|
+
- - ">="
|
97
102
|
- !ruby/object:Gem::Version
|
98
|
-
version: '
|
103
|
+
version: '0'
|
99
104
|
type: :development
|
100
105
|
prerelease: false
|
101
|
-
version_requirements:
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - ">="
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '0'
|
102
111
|
- !ruby/object:Gem::Dependency
|
103
112
|
name: regressiontest
|
104
|
-
requirement:
|
105
|
-
none: false
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
106
114
|
requirements:
|
107
|
-
- -
|
115
|
+
- - ">="
|
108
116
|
- !ruby/object:Gem::Version
|
109
117
|
version: 0.0.2
|
110
118
|
type: :development
|
111
119
|
prerelease: false
|
112
|
-
version_requirements:
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - ">="
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: 0.0.2
|
113
125
|
description: Functions and tools for tranforming and changing tab delimited and comma
|
114
126
|
separated table files - useful for Excel sheets and SQL/RDF output
|
115
127
|
email: pjotr.public01@thebird.nl
|
@@ -120,9 +132,9 @@ extra_rdoc_files:
|
|
120
132
|
- LICENSE.txt
|
121
133
|
- README.md
|
122
134
|
files:
|
123
|
-
- .document
|
124
|
-
- .rspec
|
125
|
-
- .travis.yml
|
135
|
+
- ".document"
|
136
|
+
- ".rspec"
|
137
|
+
- ".travis.yml"
|
126
138
|
- Gemfile
|
127
139
|
- LICENSE.txt
|
128
140
|
- README.md
|
@@ -148,6 +160,7 @@ files:
|
|
148
160
|
- lib/bio-table/merge.rb
|
149
161
|
- lib/bio-table/overlap.rb
|
150
162
|
- lib/bio-table/parser.rb
|
163
|
+
- lib/bio-table/parsers/fastareader.rb
|
151
164
|
- lib/bio-table/rdf.rb
|
152
165
|
- lib/bio-table/rewrite.rb
|
153
166
|
- lib/bio-table/statistics.rb
|
@@ -160,6 +173,7 @@ files:
|
|
160
173
|
- lib/bio-table/validator.rb
|
161
174
|
- spec/bio-table_spec.rb
|
162
175
|
- spec/spec_helper.rb
|
176
|
+
- test/data/input/aa.fa
|
163
177
|
- test/data/input/table1.csv
|
164
178
|
- test/data/input/table2.csv
|
165
179
|
- test/data/input/table_no_headers.txt
|
@@ -186,29 +200,25 @@ files:
|
|
186
200
|
homepage: http://github.com/pjotrp/bioruby-table
|
187
201
|
licenses:
|
188
202
|
- MIT
|
203
|
+
metadata: {}
|
189
204
|
post_install_message:
|
190
205
|
rdoc_options: []
|
191
206
|
require_paths:
|
192
207
|
- lib
|
193
208
|
required_ruby_version: !ruby/object:Gem::Requirement
|
194
|
-
none: false
|
195
209
|
requirements:
|
196
|
-
- -
|
210
|
+
- - ">="
|
197
211
|
- !ruby/object:Gem::Version
|
198
212
|
version: '0'
|
199
|
-
segments:
|
200
|
-
- 0
|
201
|
-
hash: 2239873243896303303
|
202
213
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
203
|
-
none: false
|
204
214
|
requirements:
|
205
|
-
- -
|
215
|
+
- - ">="
|
206
216
|
- !ruby/object:Gem::Version
|
207
217
|
version: '0'
|
208
218
|
requirements: []
|
209
219
|
rubyforge_project:
|
210
|
-
rubygems_version:
|
220
|
+
rubygems_version: 2.0.3
|
211
221
|
signing_key:
|
212
|
-
specification_version:
|
222
|
+
specification_version: 4
|
213
223
|
summary: Swiss army knife of tabulated data; transforming/filtering tab/csv files
|
214
224
|
test_files: []
|