Skip to content

Commit

Permalink
fixbugLoadCountData
Browse files Browse the repository at this point in the history
  • Loading branch information
hvaret committed Jun 14, 2019
1 parent 5dbaa62 commit 625dfc2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions R/loadCountData.R
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ loadCountData <- function(target, rawDir="raw", skip=0, featuresToRemove=c("alig
colnames(rawCounts) <- c("Id", labels[1])
if (any(duplicated(rawCounts$Id))){
stop("Duplicated feature names in ", files[1], ": ",
unique(paste(rawCounts$Id[duplicated(rawCounts$Id)]), collapse=", "))
unique(paste(rawCounts$Id[duplicated(rawCounts$Id)], collapse=", ")))
}
cat("Loading files:\n")
cat(files[1],": ",length(rawCounts[,labels[1]])," rows and ",sum(rawCounts[,labels[1]]==0)," null count(s)\n",sep="")
Expand All @@ -49,7 +49,7 @@ loadCountData <- function(target, rawDir="raw", skip=0, featuresToRemove=c("alig
colnames(tmp) <- c("Id", labels[i])
if (any(duplicated(tmp$Id))){
stop("Duplicated feature names in ", files[i], ": ",
unique(paste(tmp$Id[duplicated(tmp$Id)]), collapse=", "))
unique(paste(tmp$Id[duplicated(tmp$Id)], collapse=", ")))
}
rawCounts <- merge(rawCounts, tmp, by="Id", all=TRUE)
cat(files[i],": ",length(tmp[,labels[i]])," rows and ",sum(tmp[,labels[i]]==0)," null count(s)\n",sep="")
Expand Down

0 comments on commit 625dfc2

Please sign in to comment.