From e8ac62495775737aa5cada88c72a23b7b226c9d3 Mon Sep 17 00:00:00 2001 From: PratibhaPanwar Date: Thu, 28 Nov 2024 11:08:38 +1100 Subject: [PATCH] Added NEWS file. Minor text edits to clustsignal function. --- DESCRIPTION | 2 +- NEWS.md | 13 +++++++++++++ R/clustSIGNAL.R | 6 ++---- 3 files changed, 16 insertions(+), 5 deletions(-) create mode 100644 NEWS.md diff --git a/DESCRIPTION b/DESCRIPTION index 02dcdf0..789689f 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,7 +1,7 @@ Package: clustSIGNAL Type: Package Title: clustSIGNAL: a spatial clustering method -Version: 0.99.3 +Version: 0.99.4 Authors@R: c( person("Pratibha", "Panwar", email = "pratibhapanwar.4@gmail.com", role = c("cre", "aut", "ctb"), comment = c(ORCID = "0000-0002-7437-7084")), diff --git a/NEWS.md b/NEWS.md new file mode 100644 index 0000000..a75fdcd --- /dev/null +++ b/NEWS.md @@ -0,0 +1,13 @@ +## clustSIGNAL v0.99.4 (2024-11-28) +* Corrected character check for output format type. + +## clustSIGNAL v0.00.3 (2024-10-31) +* Clustering parameter options added to package +* Initial and final clustering steps are now in separate functions +* Test units added to the package + +## clustSIGNAL v0.00.2 (2024-10-08) +* Updated parallel runs in smoothing function for faster runs + +## clustSIGNAL v0.99.0 (2024-09-19) +* Submitted to Bioconductor. diff --git a/R/clustSIGNAL.R b/R/clustSIGNAL.R index 14f854f..b7faf18 100644 --- a/R/clustSIGNAL.R +++ b/R/clustSIGNAL.R @@ -87,8 +87,8 @@ clustSIGNAL <- function (spe, samples, cells, dimRed = "None", batch = FALSE, stop("NN cannot be less than 1.") } else if (!(kernel %in% c("G", "E"))) { stop("Invalid kernel type.") - } else if (!(outputs %in% c('c', 'n', 's', 'a'))) { - stop("Invalid output type.")} + } else if (!(outputs %in% c('c', 'a'))) { + stop("Invalid character for output type.")} if (dimRed == "None") { show(paste("Calculating PCA. Time", format(Sys.time(),'%H:%M:%S'))) @@ -99,7 +99,6 @@ clustSIGNAL <- function (spe, samples, cells, dimRed = "None", batch = FALSE, show(paste("clustSIGNAL run started. Time", format(Sys.time(),'%H:%M:%S'))) # Non-spatial clustering to identify initial cluster groups - # reclust should always be FALSE here spe <- p1_clustering(spe, dimRed, batch, batch_by, clustParams) # Neighborhood detection, and sorting if sort = TRUE outReg <- neighbourDetect(spe, samples, NN, cells, sort) @@ -108,7 +107,6 @@ clustSIGNAL <- function (spe, samples, cells, dimRed = "None", batch = FALSE, # Weighted smoothing guided by neighbourhood entropy spe <- adaptiveSmoothing(spe, outReg$nnCells, NN, kernel, spread, threads) # Non-spatial clustering of adaptively smoothed expression - # reclust should always be TRUE here spe <- p2_clustering(spe, batch, batch_by, clustParams) cluster_df <- data.frame("Cells" = spe[[cells]],