Skip to content

Commit

Permalink
bump to 1.23.2, fix to empty masking
Browse files Browse the repository at this point in the history
  • Loading branch information
zwdzwd committed May 12, 2024
1 parent b110baf commit 724d4c5
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 7 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Package: sesame
Type: Package
Title: SEnsible Step-wise Analysis of DNA MEthylation BeadChips
Description: Tools For analyzing Illumina Infinium DNA methylation arrays. SeSAMe provides utilities to support analyses of multiple generations of Infinium DNA methylation BeadChips, including preprocessing, quality control, visualization and inference. SeSAMe features accurate detection calling, intelligent inference of ethnicity, sex and advanced quality control routines.
Version: 1.23.1
Version: 1.23.2
Authors@R: c(person("Wanding", "Zhou", role = c("aut","cre"), email = "[email protected]", comment = c(ORCID = "0000-0001-9126-1932")),
person("Wubin", "Ding", role = "ctb"),
person("David", "Goldberg", role = "ctb"),
Expand Down
21 changes: 15 additions & 6 deletions R/mask.R
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ recommendedMaskNames <- function() {
#' @return a vector of probe ID
#' @examples
#'
#' length(getMask("MSA", "recommended"))
#' length(getMask("EPICv2", "recommended"))
#' length(getMask("EPICv2", c("recommended", "M_SNPcommon_1pt")))
#' length(getMask("EPICv2", "M_mapping"))
Expand All @@ -130,16 +131,24 @@ recommendedMaskNames <- function() {
#' @export
getMask <- function(platform = "EPICv2", mask_names = "recommended") {
stopifnot(is.character(platform))
unique(do.call(c, lapply(mask_names, function(mask_name) {
res <- lapply(mask_names, function(mask_name) {
if (mask_name == "recommended") {
do.call(c, KYCG_getDBs(sprintf("%s.Mask", platform),
res <- KYCG_getDBs(sprintf("%s.Mask", platform),
recommendedMaskNames()[[platform]],
silent=TRUE, ignore.case=TRUE))
silent=TRUE, ignore.case=TRUE)
} else {
do.call(c, KYCG_getDBs(sprintf("%s.Mask", platform),
mask_name, silent=TRUE, ignore.case=TRUE))
res <- KYCG_getDBs(sprintf("%s.Mask", platform),
mask_name, silent=TRUE, ignore.case=TRUE)
}
})))
if (!is.null(res)) {
res <- do.call(c, res)
}
res
})
if (!is.null(res)) {
res <- unique(do.call(c, res))
}
res
}

#' Mask beta values by design quality
Expand Down
1 change: 1 addition & 0 deletions man/getMask.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 724d4c5

Please sign in to comment.