rbbt-sources 3.1.32 → 3.1.33
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 +4 -4
- data/lib/rbbt/sources/CASCADE.rb +32 -45
- data/lib/rbbt/sources/MCLP.rb +1 -1
- data/lib/rbbt/sources/go.rb +0 -2
- data/share/install/Organism/organism_helpers.rb +10 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1bc10d05cb25aa6e8c21a838af30f8e910915411
|
4
|
+
data.tar.gz: 5c1443c4088a393a33513884813ef3eb9b276ff7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9c2c009324e163840751e84ec0b2eeaff7ed02588637140f26563814183ef43666c2118b92c560cf5fff56c30d9913160e0a940092b4327259f1b18d66efa7fd
|
7
|
+
data.tar.gz: dc09879abc9d3b1f60ff9ecc68f4a2d34da8dfbc19aa6cfcc5640d773d8412b8aa5e3a630dba0b8a8f54c1753dfd88d61c5b50bec8a94694798e0ab376a5804d
|
data/lib/rbbt/sources/CASCADE.rb
CHANGED
@@ -12,18 +12,8 @@ module CASCADE
|
|
12
12
|
#self.search_paths = {}
|
13
13
|
#self.search_paths[:default] = :lib
|
14
14
|
|
15
|
-
|
16
|
-
|
17
|
-
CASCADE.claim CASCADE.interactions, :proc do
|
18
|
-
io = nil
|
19
|
-
TmpFile.with_file do |tmp|
|
20
|
-
Misc.in_dir tmp do
|
21
|
-
Log.warn "Please enter bitbucket credentials to access the asmundf/cascade repo"
|
22
|
-
`git clone #{URL}`
|
23
|
-
io = Open.open("cascade/cascade.tsv")
|
24
|
-
end
|
25
|
-
end
|
26
|
-
|
15
|
+
def self.process_interactions(file)
|
16
|
+
io = Open.open(file)
|
27
17
|
tsv = TSV.open(io, :merge => true, :header_hash => '')
|
28
18
|
|
29
19
|
new_fields = ["ENTITYB"] + (tsv.fields - ["ENTITYB"])
|
@@ -36,33 +26,19 @@ module CASCADE
|
|
36
26
|
values.collect{|v| v.scan(/\d+/) * ";;"}
|
37
27
|
end
|
38
28
|
|
39
|
-
tsv
|
29
|
+
tsv
|
40
30
|
end
|
41
31
|
|
42
|
-
|
43
|
-
|
44
|
-
TmpFile.with_file do |tmp|
|
45
|
-
Misc.in_dir tmp do
|
46
|
-
Log.warn "Please enter bitbucket credentials to access the asmundf/cascade repo"
|
47
|
-
`git clone #{URL}`
|
48
|
-
io = Open.open("cascade/cascade_translation.tsv")
|
49
|
-
end
|
50
|
-
end
|
51
|
-
|
52
|
-
tsv = TSV.open(io, :merge => true, :header_hash => '', :type => :flat, :sep2 => /[,.]\s*/)
|
53
|
-
|
32
|
+
def self.process_members(file)
|
33
|
+
TSV.open(file, :merge => true, :header_hash => '', :type => :flat, :sep2 => /[,.]\s*/)
|
54
34
|
end
|
55
35
|
|
56
|
-
|
57
|
-
|
58
|
-
tsv = CASCADE.interactions.tsv
|
59
|
-
members = CASCADE.members.tsv
|
60
|
-
|
36
|
+
def self.process_paradigm(interactions, members)
|
61
37
|
proteins = Set.new members.values.flatten.uniq
|
62
38
|
outputs = Set.new
|
63
39
|
associations = {}
|
64
40
|
|
65
|
-
|
41
|
+
interactions.through do |source, values|
|
66
42
|
values.zip_fields.each do |target,typea,ida,databasea,typeb,idb,databaseb,effect|
|
67
43
|
next if typea == 'gene'
|
68
44
|
|
@@ -129,24 +105,35 @@ module CASCADE
|
|
129
105
|
str
|
130
106
|
end
|
131
107
|
|
132
|
-
CASCADE.claim CASCADE["topology.sif"], :proc do
|
133
|
-
|
134
|
-
tsv = CASCADE.interactions.tsv
|
135
|
-
|
136
|
-
str = StringIO.new
|
137
108
|
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
109
|
+
URL = 'https://bitbucket.org/asmundf/cascade'
|
110
|
+
CASCADE.claim CASCADE.interactions, :proc do
|
111
|
+
io = nil
|
112
|
+
TmpFile.with_file do |tmp|
|
113
|
+
Misc.in_dir tmp do
|
114
|
+
Log.warn "Please enter bitbucket credentials to access the asmundf/cascade repo"
|
115
|
+
`git clone #{URL}`
|
116
|
+
process_interactions("cascade/cascade.tsv")
|
117
|
+
end
|
118
|
+
end
|
119
|
+
end
|
143
120
|
|
144
|
-
|
121
|
+
CASCADE.claim CASCADE.members, :proc do
|
122
|
+
TmpFile.with_file do |tmp|
|
123
|
+
Misc.in_dir tmp do
|
124
|
+
Log.warn "Please enter bitbucket credentials to access the asmundf/cascade repo"
|
125
|
+
`git clone #{URL}`
|
126
|
+
process_members("cascade/cascade_translation.tsv")
|
145
127
|
end
|
146
128
|
end
|
129
|
+
end
|
147
130
|
|
148
|
-
|
149
|
-
|
131
|
+
CASCADE.claim CASCADE.paradigm, :proc do
|
132
|
+
|
133
|
+
interactions = CASCADE.interactions.tsv
|
134
|
+
members = CASCADE.members.tsv
|
135
|
+
|
136
|
+
process_paradigm(interactions, members)
|
150
137
|
end
|
151
138
|
|
152
139
|
CASCADE.claim CASCADE.output_nodes, :proc do
|
@@ -173,5 +160,5 @@ iif CASCADE.interactions.produce.find if __FILE__ == $0
|
|
173
160
|
iif CASCADE.members.produce.find if __FILE__ == $0
|
174
161
|
iif CASCADE.paradigm.produce.find if __FILE__ == $0
|
175
162
|
iif CASCADE["topology.sif"].produce.find if __FILE__ == $0
|
176
|
-
iif CASCADE.output_nodes.produce
|
163
|
+
iif CASCADE.output_nodes.produce.find if __FILE__ == $0
|
177
164
|
|
data/lib/rbbt/sources/MCLP.rb
CHANGED
data/lib/rbbt/sources/go.rb
CHANGED
@@ -6,7 +6,6 @@ require 'rbbt/persist/tsv'
|
|
6
6
|
# now all it does is provide a translation form id to the actual names.
|
7
7
|
module GO
|
8
8
|
|
9
|
-
extend Resource
|
10
9
|
|
11
10
|
extend Resource
|
12
11
|
self.subdir = 'share/databases/GO'
|
@@ -270,4 +269,3 @@ if defined? Entity
|
|
270
269
|
end
|
271
270
|
end
|
272
271
|
|
273
|
-
|
@@ -32,6 +32,10 @@ $biomart_transcript = [
|
|
32
32
|
$biomart_ensembl_gene
|
33
33
|
]
|
34
34
|
|
35
|
+
$biomart_transcript_cds = [
|
36
|
+
['CDS Start','cdna_coding_start'],
|
37
|
+
]
|
38
|
+
|
35
39
|
$biomart_transcript_sequence = [
|
36
40
|
['cDNA','cdna'],
|
37
41
|
]
|
@@ -209,6 +213,12 @@ file 'transcripts' => 'gene_positions' do |t|
|
|
209
213
|
Misc.sensiblewrite(t.name, transcripts.to_s)
|
210
214
|
end
|
211
215
|
|
216
|
+
file 'transcript_cds' do |t|
|
217
|
+
cds = BioMart.tsv($biomart_db, $biomart_ensembl_transcript, $biomart_transcript_cds, [], nil, :type => :single, :namespace => Thread.current['namespace'], :cast => :to_i)
|
218
|
+
|
219
|
+
Misc.sensiblewrite(t.name, cds.to_s)
|
220
|
+
end
|
221
|
+
|
212
222
|
file 'gene_positions' do |t|
|
213
223
|
sequences = BioMart.tsv($biomart_db, $biomart_ensembl_gene, $biomart_gene_positions, [])
|
214
224
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rbbt-sources
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.1.
|
4
|
+
version: 3.1.33
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Miguel Vazquez
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-02-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rbbt-util
|