Closed sunyan4BGI closed 6 years ago
You can select the cells that you want to analyse by making a new filtered loom file. However the simplest way to pick a subset of cells is to do it as a filtering steps at the beginning of analysis you can do this using the velocyto's filter_cells
method.
I tried
vlm.filter_cells(vlm.ca['CellID']==cellID_of_T_cells)
cellID_of_T_cells is the list of cellIDs
and I got
ValueError: Lengths must match to compare
This is not a problem of velocyto.
You are comparing two numpy arrays and it is up to you to do this properly. Are you sure you are doing this in the right way? Maybe you should use the numpy.in1d
function not the "==" statement.
Thanks for your reply! I now get the correct result! velocyto is really a great algorithm,it can deal with datasets that other pseudotime algorithms can't do!
I have a loom.file of 3,000 cells (from SmartSeq2). But I only want to analyze one type of about 2,000 cells. Can I select these cells from the loom.file according to CellIDs? Or do I have to create another loom.file by velocyto run?