Normalization/Scaling with sctransform in RStudio of scRNASeq data
0
0
Entering edit mode
6 months ago

Hey quick question,

I am trying to re-doing some scRNA-Seq pre-processing from a paper.

Some background information: The authors gave the cell ranger output as H5 files, which I have downloaded and loaded up in RStudio via Read10X_h5. I have created a SeuratObject out of the H5 matrix, added "percent.mt" via PercentageFeatureSet(SeuratObject, pattern = "^MT-") and then filtered after the standards of the paper: subset(SeuratObject, subset = nFeature_RNA > 1500 & nFeature_RNA < 9000 & percent.mt < 30)

Now, in paper they have written that the UMI counts were normalized/scaled using regularized negative binominal regression with the sctransform-package. If I add my SeuratObject in the function vst() I get this error:

Calculating cell attributes from input UMI matrix: log_umi Error in h(simpleError(msg, call)) : Error evaluating argument 'x' in method selection for function 'rowSums': comparison (5) is only possible for atomic and list types

Can someone explain this error to me? I don't find any helpful information if I google this error.

vst normalization sctransform scRNASeq scaling • 468 views
0
Entering edit mode

vst (FindVariableFeatures(x, selection.method = "vst", nfeatures = 2000)) requires the log normalisation, which you are not doing as you are following the SCT workflow. In you case, you need to call SCTransform after CreateSeuratObject. SCTransform wraps the normalisation and scaling (using sctranform) in one command.

0
Entering edit mode