In my last blog post, I showed that pearson gene correlation for single-cell data has flaws because of the sparsity of the count matrix.

One way to get around it is to use the so called meta-cell. One can use KNN to find the K nearest neighbors and collapse them into a meta-cell. You can implement it from scratch, but one should not re-invent the …