Convert very large sparse matrix to matrix (scRNA-seq analysis)
0
0
Entering edit mode
2.7 years ago

I'm using the Seurat object (scRNA-seq dataset) available on https://singlecell.broadinstitute.org/single_cell/study/SCP1376/a-single-cell-atlas-of-human-and-mouse-white-adipose-tissue (from https://www.nature.com/articles/s41586-022-04518-2). I extracted the UMI counts using: GetAssayData(object = adipocytes, slot = "counts") which returned a large R S4 dgCMatrix. It has everything I need, genes as row names, cells as column names, UMI counts as values. I'm trying to convert it to data frame to then use it as input on CELLEX, but because it's too big, I'm unable to convert it to data frame or matrix. Is there a way to convert this sparse matrix to data frame, keeping columns and row names?

Thanks in advance,

seurat matrix R scRNA-seq sparse • 1.6k views
ADD COMMENT
0
Entering edit mode

Can you explain a bit more what cellex is and what type of input it expects and does with it?

ADD REPLY
0
Entering edit mode

CELLEX (https://github.com/perslab/CELLEX) uses different metrics to estimate cell-type specificity profiles. The output of CELLEX is later used on CELLECT (https://github.com/perslab/CELLECT) to be integrated with GWAS summary statistics for cell-type prioritization. CELLEX uses as input a matrix of UMI counts (integer) for each gene and cell (genes are row names, cells are column names). Basically, it uses as input the exact information in the sparse matrix I was able to extract, just not in sparse matrix format.

ADD REPLY

Login before adding your answer.

Traffic: 1902 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6