You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Other than metadata generation, the effect of binarize_exp(fix_cutoff=TRUE) can be achieved with something like:
ifelse(as.matrix(assays(sce)$expdata) > 0, 1, 0)
consider this when producing a simpler more efficient binarize_exp.
Check how effective this is:
calculate zero percentage
zerop_g <- c()
#zerop_g <- c()
expdata <- assays(sce)$expdata
for (i in 1:nrow(expdata)) {
zp <- length(which(expdata[i, ] == 0))/ncol(expdata)
zerop_g <- c(zerop_g, zp)
}
#for (i in 1:nrow(expdata)) {
zp <- length(which(expdata[i, ] == 0))/ncol(expdata)
zerop_g <- c(zerop_g, zp)
#}
zerop_g <- apply(expdata==0, 1, sum)
zerop_g <- zerop_g/ncol(expdata)
The text was updated successfully, but these errors were encountered: