miga-base 1.3.8.1 → 1.3.8.2
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/miga/cli/action/doctor.rb +1 -1
- data/lib/miga/version.rb +2 -2
- data/utils/subclades.R +15 -8
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2e4abdd418e396b20fcfea4beaf4d70f3b0022808714478581e2e1f6f8a85478
|
4
|
+
data.tar.gz: 881884c4d5a933b64ac29e93397b62b7d1dc30fd599baaa8b6ac04a3ad3ab051
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 317022ffe39818af13d36e3bf1e1adea80b3ab3aafb265b3df6371b6b5e87efdb75199cf8bd22aea37a63e941f824d1686f85bdb7a38eda3f4ba2a76c535b86b
|
7
|
+
data.tar.gz: 0d42dadd982374f0c618d76fc030f5665075e9973ca8e8615c5b090ab1dcc6bf663901a8f7355ce3bfa6874941d9098957d31704b6369474e516dd5ebf8c0b6b
|
@@ -50,8 +50,8 @@ class MiGA::Cli::Action::Doctor < MiGA::Cli::Action
|
|
50
50
|
# refdb: ['ref-db', 'Check index format of reference databases'],
|
51
51
|
status: ['status', 'Update metadata status of all datasets'],
|
52
52
|
db: ['databases', 'Check integrity of database files'],
|
53
|
-
bidir: ['bidirectional', 'Check distances are bidirectional'],
|
54
53
|
dist: ['distances', 'Check distance summary tables'],
|
54
|
+
bidir: ['bidirectional', 'Check distances are bidirectional'],
|
55
55
|
files: ['files', 'Check for outdated files'],
|
56
56
|
cds: ['cds', 'Check for gzipped genes and proteins'],
|
57
57
|
ess: ['essential-genes', 'Check for outdated essential genes'],
|
data/lib/miga/version.rb
CHANGED
@@ -12,7 +12,7 @@ module MiGA
|
|
12
12
|
# - String indicating release status:
|
13
13
|
# - rc* release candidate, not released as gem
|
14
14
|
# - [0-9]+ stable release, released as gem
|
15
|
-
VERSION = [1.3, 8,
|
15
|
+
VERSION = [1.3, 8, 2].freeze
|
16
16
|
|
17
17
|
##
|
18
18
|
# Nickname for the current major.minor version.
|
@@ -20,7 +20,7 @@ module MiGA
|
|
20
20
|
|
21
21
|
##
|
22
22
|
# Date of the current gem relese.
|
23
|
-
VERSION_DATE = Date.new(2023,
|
23
|
+
VERSION_DATE = Date.new(2023, 8, 8)
|
24
24
|
|
25
25
|
##
|
26
26
|
# References of MiGA
|
data/utils/subclades.R
CHANGED
@@ -116,7 +116,8 @@ subclade_clustering <- function (out_base, thr, ani.d, dist_rds) {
|
|
116
116
|
say("Subsampling large collection")
|
117
117
|
ids <- sample(labels(ani.d), nMax)
|
118
118
|
ani.d.ori <- ani.d
|
119
|
-
ani.d <- as.
|
119
|
+
ani.d.m <- as.matrix(ani.d)
|
120
|
+
ani.d <- as.dist(ani.d.m[ids, ids])
|
120
121
|
}
|
121
122
|
|
122
123
|
# Silhouette
|
@@ -157,9 +158,10 @@ subclade_clustering <- function (out_base, thr, ani.d, dist_rds) {
|
|
157
158
|
ani.d <- ani.d.ori
|
158
159
|
# Find closest medoid for missing genomes
|
159
160
|
missing <- labels(ani.d)[!labels(ani.d) %in% names(ani.types)]
|
160
|
-
|
161
|
-
|
161
|
+
say("- Classify:", length(missing))
|
162
|
+
for (i in missing) ani.types[i] <- which.min(ani.d.m[ani.medoids, i])
|
162
163
|
# Reorder
|
164
|
+
say("- Reorder and save")
|
163
165
|
ani.types <- ani.types[labels(ani.d)]
|
164
166
|
# Save missing genomes for inspection
|
165
167
|
write.table(
|
@@ -190,11 +192,16 @@ subclade_clustering <- function (out_base, thr, ani.d, dist_rds) {
|
|
190
192
|
# Generate graphic report
|
191
193
|
say("Graphic report")
|
192
194
|
pdf(paste(out_base, ".pdf", sep = ""), 7, 12)
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
195
|
+
if (is.huge) {
|
196
|
+
plot(NULL, axes = FALSE, xlab = '', ylab = '', xlim = 0:1, ylim = 0:1)
|
197
|
+
legend('center', legend = 'Dataset too large for graphical representation')
|
198
|
+
} else {
|
199
|
+
layout(matrix(c(rep(1:3, each = 2), 4:5), byrow = TRUE, ncol = 2))
|
200
|
+
plot_distances(ani.d)
|
201
|
+
plot_silhouette(k, s[1, ], s[2, ], ds, top.n)
|
202
|
+
plot_clustering(ani.cl, ani.d, ani.types)
|
203
|
+
if (!is.large) plot_tree(ani.ph, ani.types, ani.medoids)
|
204
|
+
}
|
198
205
|
dev.off()
|
199
206
|
|
200
207
|
# Save results
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: miga-base
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.3.8.
|
4
|
+
version: 1.3.8.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Luis M. Rodriguez-R
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-08-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: daemons
|