6 Detection limit and false positive predictions
How many cells of a certain type do we need for a method to detect immune cell infiltration (=Detection limit)? How many cells of a certain type are detected, although we know they are not there (=false positives)?
We again use the single cell dataset to simulate samples that consist of background cells (i.e. non-immune cells: fibroblasts, endothelial cells cancer cells) and add an increasing amount of immune cells of a certain type.
We define the detection limit as the minimal fraction at which the method the abundance of the cell type to be significantly different from zero. We define false positives as the predicted fraction of a certain cell type at zero inflitration level.
For each amount of immune cells, we generate 5 random samples to compute a confidence interval.
We use the following cell types:
show_cell_types = c("B cell", "Dendritic cell", "Macrophage/Monocyte",
"NK cell", "T cell CD4+", "T cell CD8+",
"T cell CD4+ (non-regulatory)", "T cell regulatory (Tregs)")