yezhengSTAT / ADTnorm

ADTnorm normalizes the cell surface protein measurement of CITE-seq data, facilitating across batches and across studies data integration.
https://yezhengstat.github.io/ADTnorm/articles/ADTnorm-tutorial.html
GNU General Public License v3.0
20 stars 4 forks source link

Error in landmarkRegion[[i]] #5

Open jamesdahlvang opened 1 year ago

jamesdahlvang commented 1 year ago

Thank you for this tool! I'm excited to see how it works.

I'm currently trying to run it on a dataset with 207K cells and 46 CITE-Seq antibodies. I have 18 10X lanes merged into one object. From there, I created a dataframe with the raw ADT counts and exported the batch information as a matrix. I named those objects cell_x_adt (for the counts) and cell_x_feature (for the batch information). I then ran the following code:

cell_x_adt_norm <- ADTnorm(cell_x_adt = cell_x_adt, cell_x_feature = cell_x_feature, save_outpath = save_outpath, study_name = study_name)

And got the following error:

[1] "ADTnorm will process all the ADT markers from the ADT matrix:hash1, hash2, hash3, hash4, CD69.1, CD107a, CD154, HLA-DR, CD20, CD16, CD14.1, CD123, CD8, CD11b, CD11c, CD3, NKG2A, CD8B, CD4.1, CD27, CD1c, CD2.1, CD66b, CD56, CD206, CD163.1, TCR-Vdelta2, CD127, CD25, CD28.1, CD196-aka-CCR6, CD95, TCR-Va24-Ja18, CD183-aka-CXCR3, CD161, TCR-Va-7point2, TCR-gd-Vd1, CD279-aka-PD1, CD278-aka-ICOS, CX3CR1.1, CD194-aka-CCR4, TCR-Vg9, mIgG1-K-Isotype-Control, mIgG2b-K-Isotype-Control, mIgG2a-K-Isotype-Control, Armenian-Hasmter-IgG-Isotype-Control" [1] "hash1" Error in landmarkRegion[[i]] <- matrix(NA, ncol = 2, nrow = length(sample_name_list)) : attempt to select less than one element in integerOneIndex

Any idea what could be causing this error or what could alleviate it? Thank you!

Edit: I also named save_outpath and study_name earlier in the script.

yezhengSTAT commented 1 year ago

Hello, Have you gone through the routine quality check and filtering on this data? You probably want to plot the density distribution for each marker and each batch to see if there are abnormal values or if the the marker has very bad staining quality. ADTnorm does not have NA or zero count filtering function by far. Therefore, you will need to ensure the quality of the input data. Maybe you can start with the demo data provided in this package and see if you can make it running properly?

Thanks, Ye