diff --git a/R/methSeg.R b/R/methSeg.R index 62684c32..898a43fd 100644 --- a/R/methSeg.R +++ b/R/methSeg.R @@ -115,17 +115,17 @@ methSeg<-function(obj, diagnostic.plot=TRUE, join.neighbours=FALSE, # destrand strand(obj) <- "*" - ## check wether obj contains at least one metacol + ## check whether obj contains at least one metacol if(ncol(elementMetadata(obj))<1) stop("GRanges does not have any meta column.") - ## check wether obj contains is sorted by position + ## check whether obj contains is sorted by position if(is.unsorted(obj,ignore.strand=TRUE)) { obj <- sort(obj,ignore.strand=TRUE) message("Object not sorted by position, sorting now.") } - ## check wether obj contains at least two ranges else stop + ## check whether obj contains at least two ranges else stop if(length(obj)<=1) stop("segmentation requires at least two ranges.") diff --git a/R/methylDBFunctions.R b/R/methylDBFunctions.R index f59f1e29..97a61c57 100644 --- a/R/methylDBFunctions.R +++ b/R/methylDBFunctions.R @@ -1,10 +1,11 @@ # Helper Functions --------------------------------------------------- + #' @noRd ## function checks wether a tabix file already exists and ## appends number if file already exists .checkTabixFileExists <- function(tabixfile) { - message("\nchecking wether tabix file already exists:") + message("\nchecking whether tabix file already exists:") tabixfile <- paste0(tabixfile,".bgz") message(tabixfile) if(file.exists(tabixfile) ) { diff --git a/R/tabix.functions.R b/R/tabix.functions.R index a8053bfc..9fd47732 100644 --- a/R/tabix.functions.R +++ b/R/tabix.functions.R @@ -273,7 +273,7 @@ obj2tabix <- function(obj,filename,rm.txt=TRUE){ append = TRUE) } -#' function to check wether tabix header exists +#' function to check whether tabix header exists #' and exit with message instead of error #' #' @param tbxFile tabix file diff --git a/src/methCall.cpp b/src/methCall.cpp index 87ac8df5..e05ce889 100644 --- a/src/methCall.cpp +++ b/src/methCall.cpp @@ -953,7 +953,7 @@ int process_bam ( std::string &input, else if( (xr_tag == "ZGA") && (xg_tag == "ZGA") ) {strand='-';} // complementary to original bottom strand, bismark says + strand to this - // check wether read is proper paired (both mapped) + // check whether read is proper paired (both mapped) int proper_paired = (int) ((b)->core.flag&BAM_FPROPER_PAIR); // if is proper pair and no_overlap is set