miga-base 1.3.7.2 → 1.3.7.3

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b57ca3778ff3605473ebae2ebf69aabdb231302a59605094721c6af9cbc7a798
4
- data.tar.gz: fbe455bc223b23e5b906874fede98aa85ad443e83d3c0e87839f3bb9bf46ba29
3
+ metadata.gz: da6f90e73e7f3f740623ad77e09886b1c7618de2f484ba412e53d329fb771c12
4
+ data.tar.gz: 662eda2643f1695285e02ef18076aa3c3bed86bfbbd2d0fc9c91481fbe6fb384
5
5
  SHA512:
6
- metadata.gz: 682cc9964783ebc692be1d8358708d800caa08713b818a9aae7a6ed4d25d0874ddc553ba7e17ce2712092c9e2874353c00b90c3d8f49a3d339a33f42a7cfed6e
7
- data.tar.gz: 63e23a79b5af66e4f5816d6ece02b1f349f0477bcf46a2646328028654ffb9792a33c2ddb0e9237571112232c6e735e3a4df8433608495b43be7b6da038651c6
6
+ metadata.gz: 268833ab588449626fd9ee1c8374daea22482fe85d73570c6c9bec58dd1b00c8385e53f8c9d26f0903cf88451f715194c2ddd5bb330eff0a5695ffb9f0bcb51f
7
+ data.tar.gz: 1dabe6af4158fbb26c760aa2c4673d1cdba45b832a54eb01995418bf11a8cb7c02708e99c54a1862d9bf501101f0fc55afc6f9b44d487c37d7d35cd61a1ff688
@@ -17,7 +17,7 @@ class MiGA::Cli::Action::Rm < MiGA::Cli::Action
17
17
  end
18
18
 
19
19
  def perform
20
- if r = cli.load_result
20
+ if cli[:result] && r = cli.load_result
21
21
  cli[:remove] ? r.remove! : r.unlink
22
22
  elsif d = cli.load_dataset
23
23
  cli.load_project.unlink_dataset(d.name)
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, 7, 2].freeze
15
+ VERSION = [1.3, 7, 3].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, 6, 15)
23
+ VERSION_DATE = Date.new(2023, 6, 29)
24
24
 
25
25
  ##
26
26
  # References of MiGA
data/utils/subclades.R CHANGED
@@ -311,7 +311,7 @@ ani_distance <- function (ani_file, sel) {
311
311
  sim <- read.table(gzfile(ani_file), sep = "\t", header = TRUE, as.is = TRUE)
312
312
  }
313
313
 
314
- # If there is not data end process
314
+ # If there is no data, end process
315
315
  if (nrow(sim) == 0) return(NULL)
316
316
 
317
317
  # Apply filter (if requested)
@@ -319,7 +319,7 @@ ani_distance <- function (ani_file, sel) {
319
319
  if (!is.na(sel) && file.exists(sel)) {
320
320
  say("Filter selection")
321
321
  ids <- read.table(sel, sep = "\t", head = FALSE, as.is = TRUE)[,1]
322
- sim <- sim[sim$a %in% ids & sim$b %in% ids, ]
322
+ sim <- sim[which(sim$a %in% ids & sim$b %in% ids), ]
323
323
  } else {
324
324
  ids <- with(sim, unique(c(a, b)))
325
325
  }
@@ -329,7 +329,7 @@ ani_distance <- function (ani_file, sel) {
329
329
  sim$d <- 1 - (sim$value / 100)
330
330
  return(as.dist(with(sim, {
331
331
  out <- matrix(
332
- max(d) * 1.2, nrow = length(ids), ncol = length(ids),
332
+ min(max(d) * 1.2, 1.0), nrow = length(ids), ncol = length(ids),
333
333
  dimnames = list(ids, ids)
334
334
  )
335
335
  out[cbind(ids, ids)] <- 0
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.7.2
4
+ version: 1.3.7.3
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-06-15 00:00:00.000000000 Z
11
+ date: 2023-06-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: daemons