Control sample beta(a, b)

Beta distribution

Mean and variance

a and b

Experimental sample beta(a, b)

Beta distribution

Mean and variance

a and b

False positive rate α

Result

One-sided

Two-sided

debug

Instructions

You have M0 control samples, and M1 experimental samples. You do single-cell sequencing on each of the samples. You have an estimate of N0 and N1 cells resulting from each sample. (Note: cells in cell types whose number may vary a lot should be excluded to avoid composition effect.)

For each sample, you have an estimate of the proportion of the cell type you are interested in, that is "Mean". You also have an estimate of how the proportion may vary in different donors, that is "Std".

You then choose a threshold of p-value, say 0.05.

You can now calculate the probability of getting a false negative result.