Trying to filter loom file in R.
I have done analysis with seurat and trying to add another layer with velocity analysis scvelo (python). I could probably also do it in python with loompy library. From what I saw, the velocity analysis start from the 10x directory but I have already filtered seurat object and save it in an rds file. I have a list of ids in a csv files. I want only use these cells for the analysis of velocity.
I'm using ReadVelocity to read the loom file and then convert to seurat but then I'm trying to subset the object .
I'm trying to keep only the cells I previously kept after cleaning by mito and ribo thresholds in seurat saving into rds and exported in csv file...
But loom file come into the game and it's not fun.
Any help would be welcome. Thanks.
ldat <- ReadVelocity(file = "data.loom")
bm <- as.Seurat(x = ldat)
ids <- read.csv(file = 'daata_cellID_obs.csv', header = TRUE)
bm[["RNA"]] <- bm[["spliced"]]
dim(ids)
colnames(ids) <- "cells"
dim(bm)
bm <- subset(object = bm, cells = ids$cells)
It says "argument x is missing with no default value."
[1] 11178 1 [1] 33694 12011 Error in UpdateSlots(object = x) :
l'argument "x" est manquant, avec aucune valeur par défaut Calls: subset ... subset.Seurat -> UpdateSlots -> sapply -> lapply -> slotNames -> is Exécution arrêtée
Hello @ZheFrench, Thank you for posting the solution. I have a question regarding analysis of RNA velocity by using 'velocyto' and 'scvelo'. I have ran the pipeline of seurat to get the seuratobject. I used 'loomR' package to convert seuratobject into loom file. However, when I tried to run the following codes given in vignette http://htmlpreview.github.io/?https://github.com/satijalab/seurat-wrappers/blob/master/docs/scvelo.html , it gave me an error. I found another method -
But this particular method indicate to convert human genome gtf file to convert into spliced and unspliced loom files. I am confused now. Could you please help me with this issue? Thank you in advance.