Skip to content

Commit

Permalink
Update MAUDE.R
Browse files Browse the repository at this point in the history
Added error message to warn of duplicated rows in bin bounds table.
  • Loading branch information
Carldeboer authored Feb 20, 2020
1 parent 5390a6e commit 16d4fd4
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions R/MAUDE.R
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@ makeBinModel = function(curBinBounds,tailP=0.001){
#' @examples
#' guideLevelStats = findGuideHits(binReadMat, binBounds)
findGuideHits = function(countTable, curBinBounds, pseudocount=10, meanFunction = mean, sortBins = c("A","B","C","D","E","F"), unsortedBin = "NS", nonTargeting="NT", limits=c(-4,4)){
if(nrow(curBinBounds) > nrow(unique(curBinBounds))){ stop("Duplicate rows in curBinBounds table!")}
if(!nonTargeting %in% names(countTable)){
stop(sprintf("Column '%s' is missing from countTable; did you specify 'nonTargeting='?", nonTargeting))
}
Expand Down

0 comments on commit 16d4fd4

Please sign in to comment.