Skip to content

Commit

Permalink
Merge pull request #70 from Cristianetaniguti/main
Browse files Browse the repository at this point in the history
bugfix
  • Loading branch information
mmollina authored Jan 4, 2024
2 parents 17dc262 + d1f889b commit 055f39c
Show file tree
Hide file tree
Showing 2 changed files with 1,142 additions and 1,136 deletions.
5 changes: 3 additions & 2 deletions R/build_map_by_steps.R
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ update_framework_map <- function(input.map.list,
method = "hmm",
verbose = verbose)

a <- rem_mrk_clusters(cur.res$map,
a <- rem_mrk_clusters(input.map = cur.res$map,
size.rem.cluster = size.rem.cluster,
gap.threshold = gap.threshold)

Expand Down Expand Up @@ -337,7 +337,7 @@ add_md_markers <- function(input.map,
thresh = 500,
extend.tail = 50,
method = c("hmm", "wMDS_to_1D_pc"),
verbose = T){
verbose = TRUE){
method <- match.arg(method)
if(method == "wMDS_to_1D_pc" & is.null(input.mds))
stop("you must provide 'input.mds' when selecting method = 'wMDS_to_1D_pc'", call. = FALSE)
Expand Down Expand Up @@ -435,6 +435,7 @@ rem_mrk_clusters <- function(input.map,
id <- cbind(c(1, id+1), c(id, input.map$info$n.mrk))
## Selecting map segments larger then the specified threshold
segments <- id[apply(id, 1, diff) > size.rem.cluster - 1, , drop = FALSE]
if(dim(segments)[1] == 0) stop("All markers were discarted using the defined gap.threshold.")
id<-NULL
for(i in 1:nrow(segments)){
id <- c(id, segments[i,1]:segments[i,2])
Expand Down
Loading

0 comments on commit 055f39c

Please sign in to comment.