去除细胞周期效应——ccRemover包

原文题目:Identifying and removing the cellcycle effect from single-cell RNASequencing data

#####step1
##Normalized Data Matrix

#chooseCRANmirror()
#install.packages('ccRemover')
library(ccRemover)
browseVignettes('ccRemover')

data(t.cell_data)
dim(t.cell_data)
head(t.cell_data[,1:5])

summary(apply(t.cell_data,1, mean))

mean_gene_exp <- rowMeans(t.cell_data)
t_cell_data_cen <- t.cell_data - mean_gene_exp
summary(apply(t_cell_data_cen,1,mean))


#####step2
##The cell-cycle genes
gene_names <- rownames(t_cell_data_cen)

cell_cycle_gene_indices <- gene_indexer(gene_names, species = "mouse", 
                                        name_type = "symbols" )
length(cell_cycle_gene_indices)

if_cc <- rep(FALSE,nrow(t_cell_data_cen)) 
if_cc[cell_cycle_gene_indices] <- TRUE
summary(if_cc)


#####step3
##Putting it Together
dat <- list(x=t_cell_data_cen, if_cc=if_cc)


#####step4
##Applying ccRemover
xhat <- ccRemover(dat, bar=FALSE)

#The final step here is to add the mean values back to the cleaned data matrix:
xhat <- xhat + mean_gene_exp

#####step4+
##Settings
#If you choose to run ccRemover not using the default
#settings the following options are available to you:
xhat_2 <- ccRemover(dat, cutoff = 3, max_it = 4, nboot = 200, ntop = 10, bar=FALSE)

参考:单细胞天地——在单细胞转录组表达矩阵里面去除细胞周期影响

©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

相关阅读更多精彩内容

友情链接更多精彩内容