Skip to content

Commit d37d431

Browse files
author
Chen Ying
committed
fix overcounting issue for incompatible counts
1 parent 42dbb39 commit d37d431

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

R/bambu-quantify_utilityFunctions.R

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ modifyIncompatibleAssignment <- function(distTable){
2020
#' Process incompatible counts
2121
#' @noRd
2222
processIncompatibleCounts <- function(readClassDist){
23-
distTable <- data.table(as.data.frame(metadata(readClassDist)$distTable))[,
24-
.(readClassId, annotationTxId, readCount, GENEID, dist,equal)]
23+
distTable <- unique(data.table(as.data.frame(metadata(readClassDist)$distTable))[,
24+
.(readClassId, annotationTxId, readCount, GENEID, equal)], by = NULL)
2525
distTableIncompatible <- distTable[grep("unidentified", annotationTxId)]
2626
# filter out multiple geneIDs mapped to the same readClass using rowData(se)
2727
geneRCMap <- as.data.table(as.data.frame(rowData(readClassDist)),

0 commit comments

Comments
 (0)